To Generate msg if mandatory field is not filled

Hi Experts,
    I want to display msg if mandatory field is not filled , for that i called
CALL METHOD L_MESSAGE_MANAGER->REPORT_ATTRIBUTE_ERROR_MESSAGE
  EXPORTING
    MESSAGE_TEXT        = ' PLEASE FILL ALL MANDATORY FIELD '
    ELEMENT             =  ELEM_GENRAL
    ATTRIBUTE_NAME      =  F_NAME
But i am getting error that F_NAME is not an attribute name but it is attribute name only
What i should do , Please Help

Hi Neeraj,
Remove Required property of that inputfield make it NORMAL.
For example your input field is INPUT...
if input is initial.
* report message
          CALL METHOD lo_message_manager->REPORT_ATTRIBUTE_ERROR_MESSAGE
            EXPORTING
              MESSAGE_TEXT   = 'Pick Quantity Should not be 0... '
              ELEMENT        =  wa_temp // element
              ATTRIBUTE_NAME = 'PICK_QTY'.   // Attribute name( name used in context )
endif.
If you not fill input it will raise error message by hilighting the input field.
Cheers,
Kris.

Similar Messages

  • MP000200, screen 2044 fields are not filled

    Hi all
    We have used screen 2044 for many years, but recently som fields are not filled.
    When creating infotype 0002 and typing the ID number (PERID), the birthdate (GBDAT) is automatically filled.
    Normally these 3 fields are filled ....
    GBTAG Date of birth
    GBMON Month of birth
    GBJHR Year of birth
    ...but now the are left without values.
    Can anyone help me with that case?

    Hello,
    I'm wondering if IT22 is not subtype mandatory ... check in T582A if "Subtype obligator" isn't ticked.  Therefore you are obliged to fill the field SUBTY in your BDC.
    regards
    Hadrien

  • Read Table : Error Stating mandt field is not filled.

    Dear members,
    I am get syntax error when using Read table statement saying mandt field is not filled, however if I remove the KEY field. it is working fine.
    please let me know, where I am doing mistake. thank you.
    Data : spfli_tab like STANDARD TABLE OF spfli with HEADER LINE.
    SELECT *
           FROM spfli
           INTO TABLE spfli_tab
           WHERE carrid = 'LH'.
    READ TABLE spfli_tab
               WITH TABLE KEY carrid = 'LH'
                                           connid = '2402'.
    IF sy-subrc = 0.
    ENDIF.

    Hi...
    As Eric Said there are two ways...
    For your case use WITH KEY...
    SELECT *
    FROM spfli
    INTO TABLE spfli_tab
    WHERE carrid = 'LH'.
    READ TABLE spfli_tab
    WITH KEY carrid = 'LH'
    connid = '2402'.
    IF sy-subrc = 0.
    WRITE : 'DONE'.
    ENDIF.
    If u specify WITH TABLE KEY then u will hv to pass all key fields mentioned in DDIC...
    Hope it will solve your problem..
    Thanks & Regards
    ilesh 24x7

  • Err. E:"TRANSPORTING NO FIELDS" will not fill the output area.

    Dear all,
    Below are my codes and i keep getting this error
    E:"TRANSPORTING NO FIELDS" will not fill the output area. The addition does not make sense here.
    Any idea how to fix this?
    The first bit...
    TABLES: /BI0/MWBS_ELEMT.
      DATA:   I_MWBS_ELEMT LIKE /BI0/MWBS_ELEMT OCCURS 0 WITH HEADER LINE.
      DATA:   W_MWBS_ELEMT LIKE LINE OF I_MWBS_ELEMT.
    Then second bit...
      READ TABLE I_MWBS_ELEMT WITH KEY WBS_ELEMT = SOURCE_FIELDS-POSID TRANSPORTING NO FIELDS INTO W_MWBS_ELEMT.
      IF SY-SUBRC IS INITIAL.
        RESULT = W_MWBS_ELEMT-RESP_CCTR.
        RETURNCODE = 0.
      ELSE.
        SELECT SINGLE * FROM /BI0/MWBS_ELEMT INTO W_MWBS_ELEMT
                        WHERE WBS_ELEMT = SOURCE_FIELDS-POSID
                        AND OBJVERS = 'A'.
        IF SY-SUBRC IS INITIAL.
          APPEND W_MWBS_ELEMT TO W_MWBS_ELEMT SORTED BY RESP_CCTR.
         RESULT = W_MWBS_ELEMT-RESP_CCTR.
        ELSE.
          CLEAR RESULT.
        ENDIF.
      ENDIF.

    Hi
    The error is here
    READ TABLE I_MWBS_ELEMT WITH KEY WBS_ELEMT = SOURCE_FIELDS-POSID TRANSPORTING NO FIELDS INTO W_MWBS_ELEMT.
    The addtion TRANSPORTING NO FIELDS is in conflit with addition INTO:
    TRANSPORTING NO FIELDS means not to fill the work are
    INTO mean fill a work area
    So or u need to fill a work area or u don't need to fill a work area, but (from the code you've pasted) it seems u need to fill the work area W_MWBS_ELEMT, so your code should be:
    READ TABLE I_MWBS_ELEMT INTO W_MWBS_ELEMT WITH KEY WBS_ELEMT = SOURCE_FIELDS-POSID.
      IF SY-SUBRC IS INITIAL.
        RESULT = W_MWBS_ELEMT-RESP_CCTR.
        RETURNCODE = 0.
      ELSE.
        SELECT SINGLE * FROM /BI0/MWBS_ELEMT INTO W_MWBS_ELEMT
                        WHERE WBS_ELEMT = SOURCE_FIELDS-POSID
                        AND OBJVERS = 'A'.
        IF SY-SUBRC IS INITIAL.
          APPEND W_MWBS_ELEMT TO W_MWBS_ELEMT SORTED BY RESP_CCTR.
         RESULT = W_MWBS_ELEMT-RESP_CCTR.
        ELSE.
          CLEAR RESULT.
        ENDIF.
      ENDIF.
    Max

  • How to block the 'save' function when the required fields are not filled?

    Hello, Everyone
    I am new for this scripting. My question is:
    How to block the 'save' function when the required fields are not filled?
    I designed a PDF file with some required fields and I do not want the user to save the document until all required fields are filled. My idea is to write some scripts in Willsave method like:
    if (this.getField("Family Name").value == ""){
    app.alert('You should fill the Family Name field firstly!');
    But I do not think it works as finally the document is saved after all.
    Please help me on that!
    So much thanks.

    Dear Randybearwang,
    I am a Rocky myself and I know how though it is to establish some good codes. Since I created some forms with validation options myself I might have a code for you. The code also creates an alert box (Yes/no option) if the user chooses yes the form will be validatet, if he chooses "no" the alert window will be closed.If  everything is filled out correctly the form will be saved otherwise the textbox will be higlighted and gets focus.
    If you need further assistance , please let me know
    Have fun with the code.
    P.s I don´t know how to upload the "PDF" document. I wrote you an email, please get back to me if you still need the file.

  • FI:While posting MIRO getting Error of Balancing field Segment not filled

    Hello SAP Gurus,
    While  posting MIRO getting Error of Balancing field Segment in line item 001 not filled
    Message No.GLT2201.
    Please suggest me solution for it i read lots of related threats but could not solve this error.

    SPRO-Financial Accounting (New)-General Ledger Accounting (New)-Business Transactions-Document Splitting-Edit Constants for Nonassigned Processes-Select your constant-Double click and Select Assignment of profit center- Enter your dummy profit center here   otherwise
    SPRO-Financial Accounting (New)-General Ledger Accounting (New)-Business Transactions-Document Splitting-Edit Constants for Nonassigned Processes-Select your constant-Double click and Select Assignment of values-Enter here segment.

  • LSMW for Chart of Account: Field XSPEB not filled in batch-input session

    Hi all,
    we are using LSMW for importing the chart of account into a new system.
    The LSMW project uses the report RFBISA00 for the creation of the batch-input session.
    Some accounts need to be blocked in the new system. Therefore, we have the field XSPEB in our source structure and of course also in our target structure. But after the creation of the batch-input session the field is not included in the corresponding batch-input session.
    Does anybody know why it is not set? I already debugged the program RFBISA00 but couldn't find the place where the data get lost.
    Thanks in advance and regards,
    Martin

    Did your batch input end with save ( /11 ) or what ok_code are you using ?

  • End User Personalization - Mandatory field does not make it mandatory

    I am on GRC 5.3 SP8 and when I set "Company" as "Mandatory" under "End User Personalization", it does not put an "*" next to Company or force the user to fill in the Company field. 
    How can I make sure that the user enters "Company" when doing a "Create Request form"?  I want to make sure a red "*" is next to the field so that they update it.  Right now I have a default value in there but I want to make sure they think about what goes in this field.
    When I create a custom field and use "end user personalization", the red "*" shows up and an error occurs if they don't fill in the field, but the predefined fields don't work the same way. 
    Thanks,
    Peggy

    GRC Experts, please correct me if I'm wrong but from my understanding, the Request Screen in the MyWork tab is for Approvers/Admins/Security i.e. those with UME permissions of some kind. This is not the Request Screen for end users. We actually customize our UME roles to elimate the ability to use this Request Screen. We want all of our security requests to be done in the End User Request Screen.
    Unlike the MyWork Request Screen, the End User Request Screen is customizable under configuration-->End User Personalization. As you've noticed, here you can customize what fields you see on the End User Request Screen, what fields are defaulted, etc. For example, for our company, we do not want end users picking and choosing roles. Our end users are not knowledgable on our roles so we save that step for a stage in which Security Admins choose roles for users based on what they asked for in the Request Reason.
    Another advantage of using the End User Request Screen is that end users can create requests without having UME permissions; they need only to be authenticated against whatever system you have chosen to authenticate them against (for example, SAP) Configuration-->Authentication. As long as they exist in that system, they can create a request.
    Every company is different. For us, we don't like that the MyWork Request Screen is not customizable and requires UME permissions to even access it. So we have essentially taken it away through security (based on the Security Guide provided by SAP).

  • Why does the mandatory field indicator (*) not aligned in Firefox 4.0?

    [http://i56.tinypic.com/24ng1vt.png Asterisk not aligned in Firefox 4.0]

    Who makes your mouse? Is it a Logitech? If so, please see this post: http://forums.mozillazine.org/viewtopic.php?f=38&t=206293

  • Field MWSKZ not filled in VBRP

    Dear all,
    I would like to have the tax code field (MWSKZ) filled in VBRP. Now this field is left empty in my sales flow.
    On the purchase side (EKPO) this field is filled with the tax code.
    It would be important, because, afterwards, my Intrastat declaration must be able to filter on tax code.
    Thanks in advance for your help!

    Hi Willem,
    with the available information, i could only suggest you to get into debugging to find out the exact reason.  Try looking into the copy control data transfer routines, if something is messed up there. Check if nothing is affecting LANDTX as that field has the impact on tax calculations.
    Do you need the tax code in billing table to do your intrastat reporting. As accounting document is capturing the correct tax code, you should be able to run the accounting settlement reports for intrastat reporting.
    Thanks
    Kapil Sharma

  • Reg: Mandatory fields updation with BAPI

    Hi..
    We are working on BDC using BAPI. In this if flat files contians only 4 fields and the mandatory fields in the application are seven then system needs to through error message. But with BAPI the program is updating the database without throwing error eventhough all mandatory fileds are not filled up with data.. Where exactly we need to do modifications to get error message when mandatory fields are not filled up with input.
    Regards

    Hi Verendra
    Sometimes the function modules/BAPI's used by SAP do a direct update on the database tables. In such scnearios the entries are created in the system even though if the mandatory entries are not filled.
    If the number of mandatory fields are small, then before the BAPI call,  check if all the mandatory fields are filled or not;throw error in case of empty fields & bypass the BAPI call.
    In case the mandatory fields are too high, then in that case, please use BDC recording to update the data.
    Regards
    Chetan
    PS:Reward points if you find this helpful.

  • Mandatory field quey

    i have a mandatory field in my report
    suppose i press exit or back button without entering data in mandatory field will that exetute or it will exit only when data is entered in that field
    is this also same in case of module pool screen

    In Reports: If you click Exit or Back button without filling the mandatory field, the system will allow you to exit from the screen .
    In Module pool program : The back button wont allow to go back(as per SAP standard), if the mandatory field is not filled. But for the Exit button in pf status if the functional type is declared as 'E'  (Exit command )is given and if you have written a module in PAI like MODULE <modulename>AT EXIT-COMMAND.
    MODULE <modulename> INPUT.
      CASE OK_CODE.
        WHEN '<function code>'.                     
          LEAVE PROGRAM.
    ENDCASE.
    it will allow you to exit from the screen.
    Edited by: Jeniphin on Apr 3, 2008 4:22 PM
    Edited by: Jeniphin on Apr 3, 2008 4:23 PM

  • Dynamic mandatory field error message is not getting displayed in webui

    Hi,
    In Appointment if the importance is HIGH i made Location as mandatory.For this i enhanced BT126H_APPT/ApptDetails. In the get_p_location() method of BTACTIVITYYH i have written the code.
    Now the problem is Error message for this dynamic mandatory field is not getting displayed in webui.
    I debugged in DO_FINISH_INPUT error message is getting generated but it is not getting displayed in ui.
    Can anybody tell where the problem is?
    Thanks,
    Hari.

    Hi Hari,
    Really sorry do not know how to convert this nug file to text
    How ever quick solution for your problem would be just keep your validation in 'DO_VALIDATE_INPUT' method of the view controller.
    Means even if the User clicks on SAVE , Since it fails here , it would not allow you to go further.
    Thanks,
    Rajesh P

  • Mandatory Fields in iView created from SHD0 (sceen variant)

    I am experiencing an issue with the Portal display of an (IAC) iView.  The iView displays PZ05 and a transaction variant was setup to handle Emergency contact info.  I created a screen variant for the second screen of this transaction (screen 0200) in which I made 7 of the fields mandatory in the variant.  When this is tested on the R/3 side the mandatory fields are displayed the way they are supposed to be (with the check mark in the box, denoting it as a required field) however when they are displayed in the iView on the Portal the mandatory fields are completely filled up with the "check mark in the box".  In other words the "Name" field is 40 character... and there are 52 "check marks in the box" characters filling up the field.  The iView works great but this looks ugly.  Any suggestions on what I should do to rectify the situation?
    We are running Portal 6.0 SP15 with a stand alone ITS on a 4.6c backend and the Business Package is 50.4.

    Hi Balaji,
    When you create Vendors properly in ECC it should not give such an error. You have to maintain basic data, Accounting data and purchasing data. Rest all are optional.
    For replicating vendors from R/3 to SRM you should have a Vendor root org / group in SRM. BBPGETVD is used to replicate vendors to SRM by mentioning the logical system and Vendor Group ID.
    Hope this makes you clear. Please explain the error clearly for further help.
    Award points for helpful answers.
    Rgds,
    Teja

  • Missing Mandatory field in IDOC

    Hi All,
            There is one outbound idoc which gives out an error status 40 "Application document not created in target system".
    The error is Missing mandatory field : 1CS210,, not sure how tor find this missing field since the name does not match with the field names in the segments.
    Can anyone help me?
    Regards,
    Anand

    hi shiva,
    pls try the below links you may get solution.
    http://sap.ittoolbox.com/groups/technical-functional/sap-log-sd/mandatory-condition-mwst-is-missing-388959
    Missing fields in Customer Master Data - 41k -
    Re: Web Service - Error in Connection and Data fields missing - 44k -
    http://blogs.ittoolbox.com/sap/ehadzipetros/archives/no-mystery-to-troubleshooting-gis-and-sap-always-begin-at-the-beginning-22646
    www.helpsap.com/account1.html - 14k
    thanks
    karthik
    reawrd me if helpfull

Maybe you are looking for