Application Development Discussions
Join the discussions or start your own on all things application development, including tools and APIs, programming models, and keeping your skills sharp.
cancel
Showing results for 
Search instead for 
Did you mean: 

Warning messages didn't show up

Former Member
0 Kudos

Hello,

I am trying to implement modification, that posting in transaction VL02N will display warning message when budget is exceeded. Solution is attached to Note 985734 and described in Note 447102:

"However, if you use transactions MIGO, MB1A, VL01, VL01N, VL02 or VL02N to carry out postings, the CO checks run.

However, the posting is only then interrupted if the system issues error messages. In this case, all warning and error messages, in particular those of the availability control, are logged.

If the system does not issue any error message during the posting, but issues an availability control warning message, which is linked with an e-mail to the person responsible (this conforms to action 2 in the definition of the tolerance limit of the availability control), the posting is not interrupted as described above and the system does not issue an availability control warning message. However, an e-mail is sent to the person responsible."

I slightly modified the modification to include transaction VL02N and my problem is that after statement MESSAGE is executed, the message don't come up and the program flow continues and I don't understand why. Here's a link to youtube with my debugger: http://www.youtube.com/watch?v=N7aB0pzjLgs

Could someone explain me why the warning message didn't show up, please?

Thanks,

Pavel Kraxner

P.S. In the end of the video is a comment in notepad that error messages are working OK, which is correct, but they are executed at different place (AC_DOCUMENT_CREATE returns sy-subrc = 1 in contrary to Warning messages) .. on that particular place any message didn't show up and I don't know why..

1 ACCEPTED SOLUTION

former_member156446
Active Contributor
0 Kudos

Hi Pavel... I appreciate your kind of asking question with a youtube link of your session...

There are some places / user exits / BADI where you cannot raise any messages... even if you hard code to raise a mesage the program would rather dump, but will not raise any messages... I suspect you are in such a place.

Solution for it.. look for an alternate place to place your code...

or see if the message class / number is present and have some text assigned to it.

4 REPLIES 4

former_member156446
Active Contributor
0 Kudos

Hi Pavel... I appreciate your kind of asking question with a youtube link of your session...

There are some places / user exits / BADI where you cannot raise any messages... even if you hard code to raise a mesage the program would rather dump, but will not raise any messages... I suspect you are in such a place.

Solution for it.. look for an alternate place to place your code...

or see if the message class / number is present and have some text assigned to it.

Sandra_Rossi
Active Contributor
0 Kudos

there is probably a place where there is a CALL FUNCTION ... EXCEPTIONS error_message = ...

If any message is sent inside the function module (or in one of its called procedures, at any level), then these messages are ignored. That's explained in [sap library|http://help.sap.com/saphelp_nw2004s/helpdata/en/9f/dbaa0635c111d1829f0000e829fbfe/frameset.htm].

To check that, look at all the function modules which are displayed in the abap stack (in the debugger), and check how they are called.

0 Kudos

Thanks for help, the function module was called with the error_message exception. What I don't understand is that the code with the non-working MESSAGE statement was not my code, but correction attached to SAP note 985734, so I don't understand how that could ever work.... anyway, I will do some workaround based on your info.

Edited by: Pavel Kraxner on Jul 27, 2010 1:36 PM

Edited by: Pavel Kraxner on Jul 27, 2010 1:41 PM

Former Member
0 Kudos

Thanks for the info.