Warning message in an User Exit

Hi folks,
        In an user exit, I have to check a condition, and if it is satisfied i need to display a message box with some warning information. I am not supposed to use FM like 'POPUP_WITH_WARNING' as it is displaying big box.  So i am trying to use message-id with warning type. But as it is a exit (include program), i am unable to define a message-id in the include program. Is there any way to define a message in an user exit include or do we need to use any FM to display pop up warning message.
Please suggest me.
                       Thanks,
                       Shyam.

you need not define the Message Class in user-exit. You can use the system class SY
write the code as
message w499(sy) eith <text>
where 499 = message number
          sy = message  class
hope this helps,
Raj

Similar Messages

  • Message error on user-exit MV50AFZ1

    Hi!
    I need to send a message error on user-exit MV50AFZ1 (VL01N), but I can't, because when I use BAPI_DELIVERYPROCESSING_EXEC for create deliveries, it will abort my program.
    My program try to create many deliveries together, when occurs a message error, I don't know what order is the problem!!
    Thanks,
    Tatiana

    Hello.
    In the exit, use a condition like:
    IF sy-tcode EQ 'VL01N'.
      MESSAGE E000(...)
    ENDIF.
    This will avoid the error in BAPI execution.
    Regards,
    Valter Oliveira.

  • Screen: illegal message in asset user exit

    hi all,
    I have done some validations in asset master user exit for some of the field while creating asset.
    If for some valiation I put an error or warning message i.e.
    message e001(zclass).
    It just holds the screen and I cannot change the values. If I click BACK or EXIT button then it gives short dump saying:
    screen: illegal message
    During "Exit Command" processing, the program tried to send a " " message. 
    This is not allowed at this point in processing.                           
    The program had to be terminated.                                                                               
    Screen name.............. "SAPLAIST"                                       
    Screen number............ 1000                                             
    Please advise.
    Regards,
    FS

    Can u explain with example how you perfomed the check for the exit routine.
    Thanks,
    Noufal.p

  • Display error message in SD user exit

    Hi,
    I want to display an error message in FORM USEREXIT_CHECK_VBAP. (Include MV45AFZB)
    Afterwards, the user should be able to correct the wrong values, but the fields are locked because of the error message. How can I keep the relevant fields open?
    Thanks in advance
    Roland

    Hi,
    Instead of giving an error message...Probably give warning message..
    If you give error message..It will lock the entries..
    Thanks,
    Naren

  • Dumb question about E messages generated in user exits called from dialogs

    After a user enters goods receipt info in MIGO and hits POST, there is a user exit (EXIT_SAPLIE01_007) which receives a copy of the goods receipt table (xmseg) from MIGO and lets you do whatever you want before the MIGO update task is called.  In other words, you're still in the MIGO dialog process.
    I have successfully used this exit before to pop an editable ALV that lets the user enter custom data per line item, and then store this data in memory so it can be accessed in MB_DOCUMENT_BADI or in the equivalent XMBC exit (enhancement MB_CF001).
    But here's my question.
    Suppose I generate an "E" message in EXIT_SAPLIE01_007. 
    Will this stop the MIGO "POST" so that the update task isn't called?
    And will the text of the "E" message be displayed at the bottom of the main MIGO screen (the one you hit "POST" from) ????
    Edited by: David Halitsky on Feb 21, 2008 9:03 PM
    Edited by: David Halitsky on Feb 21, 2008 9:04 PM

    Hi David,
    it seems that you will get it:
    E in Status bar
    +behaviour:     +
    PAI processing is terminated, and control returns to the current screen. All of the screen fields for which there is a FIELD or CHAIN statement are ready for input. The user must enter a new value. The system then restarts PAI processing for the screen using the new values. Error messages are not possible in POH or POV processing. Instead, a runtime error occurs.
    according to help [http://help.sap.com/saphelp_nw70/helpdata/en/9f/dbaabc35c111d1829f0000e829fbfe/frameset.htm|http://help.sap.com/saphelp_nw70/helpdata/en/9f/dbaabc35c111d1829f0000e829fbfe/frameset.htm]
    best regards,
    Wojciech

  • Message type in user exit

    Hi,All,
    In Tcode AS01,I use user exit AISA0001 to check the value of ANLA-SERNR,if the value did not fit the rule,raised an error through "message ... type 'E' or message exxx with ...", now the problem occured, although I enter new value for the field SERNR,in the user exit, I got the old value,It seemed that the PAI did not trigged again.
    Does anybody can help?
    Thanks very much!
    Pole
    Message was edited by: gw gw

    Hi there,
    Not sure if this will help as im not sure at what point the user exit is called, but there is a method to access field values available in the main SAP program from within the user exit using field symbols. The code for this is as follows:
    field symbol declaration
      FIELD-SYMBOLS: <status>.
    Assign value of variable from calling prog to field
    symbol
      ASSIGN ('(SAPMM06E)RM06E-BSART') TO <status>.
    The value will now be contained in the field symbol
    <status> which can be used as usual i.e.
      message exxx with <status>.
    Hope this helps
    regards
    Mart

  • Best practice on integration message augmentation via user exit or rfc call

    I am looking for documentation that would provide best practices on whether to use user exits to augment the data on an IDOC or to forward the standard SAP produced IDOC to PI where rfc calls are made to augment the data as required for the specific target system.
    I am sure there are pros and cons for both solutions, but I am hesitant to use user exits since we now have moved the knowledge of what a target system wants from the integration layer to the source layer.  If a second target system comes along in the future, the user exit becomes more complicated with additional target specific requirements. 
    Any links to best practice documentation on this subject is greatly appreciated.
    Edited by: Sean Sweeney on Oct 15, 2009 6:59 PM

    Hi Steve,
    Might be trying for solution for a long time, If i understood your question clear let me clarify you few points.
    You are trying to access the bex query which is designed with the exit's in the background based on the logic and trying to call the entire dimensions and key-figures in a single connection. Then you are trying to map those data in the charts.
    Steve, try to make more connections based upon the logic and split them. use the same query but split them by sales per customer group, sales per day, sales per week by making three different connections and try. You can merge the prompts from all connections.
    Hope this Helps!!!
    Sorry if i misunderstood your question.
    --SumanT

  • VA01-VA02 : Error message in a user exit / MV45AFZB

    I everyone,
    i want to add an error message in the exit "USEREXIT_CHECK_VBEP" (MV45AFZB) but when i do so it displays the following abend message :
    "Incorrect index structure for table XMVERF_POS
    /0000000222 /000030 "    (V1322).
    just after mine.
    do you have any idea ?  
    Xavier.
    PS : I use SAP ECC5

    Hi Xavier,
    Here is the explanation when you get this type of error:
    Short Text
    Incorrect index structure for table &
    Diagnosis
    Internal error.
    Procedure
    Repeat the transaction.
    If the error occurs and you have a CRM System connected to your ERP System, the document may have been archived in the CRM System.
    If the error occurs again, inform your system administrator. If the error cannot be corrected, call the SAP Hotline directly. Describe which steps preceeded the error.
    This is the long text description of that error message, so please let me know what next i mean whether you checked this and took the necessary action as explained above.
    let me know if your problem still persists, else kindly close the thread.
    Regards,
    Yugandhar

  • WARNING MESSAGE in USER EXIT

    Hi ,
    We are not able to TRIGGER a WARNING MESSAGE but we are able to TRIGGER an ERROR MESSAGE for a particular Business Scenario in side a user Exit.
    Any way we can produce the WARNING MESSAGE from the USER EXIT.
    Regards,
    Sap User

    Hi sapuser,
    1. We can issue message of type 'I'
      (messsage of type W
      gets displayed on status bar,
      and if the standard transaction,
      again display some its own message,
      then our message will be overwritten)
    2. it will be displayed in a message box.
    regards,
    amit m.

  • User Exit for VA41 Validity Date

    Hi,
    I am giving order type in VA41 Tcode and then Clicking on 'Create with Reference' .Then a Pop Up is getting generated. In this i am giving Contract created with validity date lessthan today's date(in Contract Tab).For Example i created a Contract xxxxxx with 'valid to' 9.12.2008. When I am giving this contract and clicking on 'Copy' button a Warning message is getting generated 'The sales document is only valid until 09.12.2008'. Now i have to change this into Error message instead of Warning Message.
    i used User Exits mv45afzz,MV45AFZA,MV45AFZB. But the debugger is getting started only after Warning message got generated.Is there any User Exit for which debugger gets started when i give the Contract and then Click on 'Copy' button. Please Suggest.
    Thanks
    K Srinivas

    Hi,
    Create a file say breakpoint.txt file as follows:-
    [FUNCTION]
    Command=/H
    Title=Debugger
    Type=SystemCommand
    Once you come to the screen of 'Create with reference' where you are giving the contract, from  second session drag the above mentiuoned file to the session where you are running VA41, & drop it here. Now debugger has been activated. Proceed with debugging. This method you can use for any of the 'POP UPs'.
    I hope this helps,
    Regards
    Raju Chitale

  • User Exit for Validity Date for VA41 Tcode

    Hi,
    I am giving order type in VA41 Tcode and then Clicking on 'Create with Reference' .Then  a Pop Up is getting generated. In this i am giving Contract created with validity date lessthan today's date(in Contract Tab).For Example i created a Contract xxxxxx with 'valid to'  9.12.2008. When I am giving this contract and clicking on 'Copy' button a Warning message is getting generated 'The sales document is only valid until 09.12.2008'. Now i have to change this into Error message instead of Warning Message.
    i used User Exits  mv45afzz,MV45AFZA,MV45AFZB. But the debugger is getting started only after Warning message got generated.Is there any User Exit for which debugger gets started  when i give the Contract and then Click on 'Copy' button. Please Suggest.
    Thanks and Regards
    K Srinivas

    Hi,
    One idea. Go to VTAA (copy between sales docs) and create a new VOFM where you manage the copy control. Set a warning/error message in the new VOFM (in your range number), and try it.
    Regards,
    Eduardo
    Edited by: Eduardo Hinojosa on Dec 10, 2008 3:58 PM

  • User-exit  for displaying message in LT15

    Hi,
    I am looking for a user-exit (or another way?) for displaying a warning message when the user tries to cancel a TO via LT15 (under certain conditions). But the only user-exit that I found that would do the thing here is ZXLTOU02, but it's performed only in Update task - no message display possible.
    Any ideas?
    Cheers!

    Thanks for your input Chidanand,
    But I've already tried by setting a breakpoint in all available exits concerning TO confirmation/cancellation - none of them is reached when LT15 is executed. The only one is the one I mentionned, and it is being performed in update task - so no message issuing possible.....
    Any other ideas?

  • User exit message problem

    hi all
    i am giving an error message in a user exit the error message comes as a pop up and moving ahead takes me out of the transaction i seriously donot want this.
    even worning messages are coming as success ones
    is there a way out for giving error msg
    regards
    navjot

    Post details of the transaction code you are trying to issue the message in, and of the exit you are using.
    Often transactions have multiple user exits, and you may be using the wrong one to issue the message.
    In some cases like Purchase Orders you need to call SAP code / macros to add the message to a list of messages that the standard screen will then display.
    Andrew

  • Message to display in MIGO user exit

    Hi everyone,
    I have used a User Exit EXIT_SAPMM07M_001in migo for automatic batch generation, the problem is that when I give the message in the user exit it does not pop up the information.
    E.G. message 'Batch is xyz' type 'I'
    also i have tried to use the function module POPUP_TO_CONFIRM but this also does not give a pop up display.
    How can I go about giving a message popup in MIGO .
    regards
    Yao Chhang

    Maybe it's not running the code in the exit.
    You can check this by add some lines to a logfile on the application server for testing purposes.
    data: l_dataset type string value '/export//intf/abaptemp/zzhstest0001.txt',
          l_string type string,
          l_string2 type string value '**********************************************'.
    open dataset l_dataset for appending in text mode encoding default.
    l_string = 'Test 1'. transfer l_string to l_dataset.
    concatenate sy-Datum sy-uzeit sy-uname into l_string. transfer l_string to l_dataset.
    l_string = l_string2. transfer l_string to l_dataset.
    close dataset l_dataset.
    Run the program.
    Check the logfile.
    regards,
    Hans
    Please reward all helpful answers !!!!!

  • IW31/IW32 User exit to kick off on clicking enter

    Hi All,
    I have a requirement which is as follows.
    In transaction IW32 if I go to partner data for an order and put a partner number and when I click enter, a message should be displayed for the user.It could be an error or warning message.
    The user does not want this message while saving the order (IWO10009-user exit for save event) and instead wants to kick off this message when he presses enter.
    Is there any user exit or BADI available to achieve this?
    Can anyone tell me how to do this?
    Thanks
    Sandeep

    check these...
    Enhancement/ Business Add-in            Description
    Enhancement
    IWO10012                                Maintenance order: Priority handling on central header
    Business Add-in
    IWO_UI_USEFLEX                          BAdI for Calling Up an Alternative UI

Maybe you are looking for