‎2006 Dec 12 4:06 PM
hI All.
I am trying to create a sales order and when i enter data and hit enter it comes with error message. I want to put a break point where the message is.. how could i know that point.
thanks in advance.
‎2006 Dec 12 4:10 PM
hi Shejal,
Use /h and run your transaction to track where exactly you are getting that error message ..
Regards,
Santosh
‎2006 Dec 12 4:09 PM
Type /h in the command line and then hit enter. Now it will enter in to debug mode.
Now, in one of the menu options of the Break Point, it will be Break Poiint at statement, you will get a pop up, type MESSAGE.
Now, you have a break point at every MESSAGE statement in the program.
Regards,
Ravi
‎2006 Dec 12 4:14 PM
Ravi,
I have tried the same number of times but it dosent stop and is directly showing the error message.
Stpes that I have done,
/h
enter into the debug mode, as you said menu options, break point and at statement typed in messages
excute
goes to required screen
enters wrong data and hit enter. pops up the error message.
In addition tot his shoud i do somethig else.
Thanks,
‎2006 Dec 12 4:17 PM
Like Ferry pointed out, it might be a system exception. try his idea.
Else, you can search for that specific message number in the MAIN program and set the break point at that specific place.
Regards,
Ravi
‎2006 Dec 12 4:10 PM
Hi,
After you put '/h' at command line then run the transaction code/progam.
The system will stop then you go to breakpoints (menu) -> breakpoints at -> Statement -> type message.
OR
you go to breakpoints (menu) -> breakpoints at -> system exception.
Regards,
Ferry Lianto
‎2006 Dec 12 4:10 PM
hi Shejal,
Use /h and run your transaction to track where exactly you are getting that error message ..
Regards,
Santosh
‎2006 Dec 12 4:10 PM
Hi Shejal,
Double click on the message and find out the message class and message number
now goto SE91 , give the message class and goto that message number
find out the where-used-list of that message
then u will get ur program , doublick on that and put break point
‎2006 Dec 12 4:12 PM
Hi,
check the program name in system_status and try to find the message in the program ,set a break point there.
hope this helps,
keerthi
‎2006 Dec 12 4:14 PM
Hi Shetty,
Click on the error message that was displayed then it will show the message class and message number.
search for that message number in the program globally. then just keep a break point over there.
Regards,
Satya
‎2006 Dec 12 4:22 PM
Hi,
You should give message instead of <b>messages</b>
Stpes that I have done,
/h
enter into the debug mode, as you said menu options, break point and at statement typed in <b>messages</b>
excute
goes to required screen
Thanks,
Naren
‎2006 Dec 12 4:25 PM
‎2006 Dec 12 4:26 PM
Hello,
Before Entering put /h.
Then enter.
In the menu > breakpoint>statement-->Message and enter and F8.
If useful reward,
Vasanth
‎2006 Dec 12 4:28 PM
Hi,
Is it a standard sap message...If it is a standard sap message then message id will NOT start with 'Z' or 'Y' message ID..
Let us know the message ID and No..So that I can try getting you the program..
Thanks,
Naren
‎2006 Dec 12 4:36 PM
It is a standard SAP message.
when i enter wrong material number in MFBF and hit enter it pops out with this message.
Entry 101 does not exist in mara -check yoyr entry.
I also looked into the technical information,
Appl area 00
message number 058
I could take a screen shot of it but is there any option in SDN to paste it.
thanks,
‎2006 Dec 12 4:32 PM
Hi Shejal,
If you know the message class and number.
Please go to SE91 and find where is being used and related to the program that you are working with. Then set break point there and when you run your transaction/program, the system should stop there.
Regards,
Ferry Lianto
‎2006 Dec 12 4:44 PM
Hi,
This message is a system error message...Since the field RM61B-MATNR has been set up with foreign key relationship with MARA..
As the entry 101 is not there in MARA ...THe error message is coming..
Try doing system debugging..
Thanks,
Naren
‎2006 Dec 12 4:47 PM
I am entering the wrong number because i wont to copy the code where it is populating the error message and paste in for a custom program.
Thats the reason I am trying to get the point of error message. As suggested I have tried in SE91 and it gives many programs.
Anyways thanks,
‎2006 Dec 12 4:50 PM
Hi,
If you are copying the code..The system will take care of giving the error message as foreign key relation is maintained for that field with the table MARA..
Thanks,
Naren
‎2006 Dec 12 5:03 PM
Yaa thats true but my concern is where is the code, I mean where is the point of message,
I was debugging the entire program and the main program - SAPLBARM, screen 800 the message is populated but i dont see the code.
It comes and stops at the BOLD line in the below specified code.
PROCESS AFTER INPUT.
MODULE exit_backflush AT EXIT-COMMAND.
zuerst die Werksdaten lesen note 524622
<b> CALL SUBSCREEN tabsub800. " note 524622 </b>
CALL SUBSCREEN sub800. " note 524622
CALL SUBSCREEN subhr.
MODULE get_hr_data.
CALL SUBSCREEN fco_sub.
MODULE get_fco_data.
MODULE check_input.
MODULE check_fcode.
‎2006 Dec 12 5:10 PM
Put one "Breakpoint at statement" with statement MESSAGE.
Regards.
‎2006 Dec 12 5:13 PM
Although this seems like the best way to do this (break-point at a message), SAP often hides messages very deeply. In other words, the program finds something it doesn't like, but instead of just raising a message, it passes some parameters to a FM that calls another FM, etc. until the actual message is issued. And that really doesn't tell you much.
I think a simpler approach is to debug from the beginning. Execute high level modules one at a time until the error appears. Then go back and start again. When you come to the module that raised the error, execute it line by line, but execute any modules that are called again at the higher level (F6 I think).
You have to do this a number of times, but eventually you will see where the error originated.
Rob
‎2006 Dec 12 5:39 PM
Thanks Guys for all the help.
I am duplicating the MFBF screen ans was trying to copy the code if user enters wrong material.
Instead i changes my selection screen.
I introduces a value check in the selection screen and it gives me the message.
SELECTION-SCREEN: BEGIN OF BLOCK 1 WITH FRAME TITLE TEXT-001.
PARAMETERS : P_ERFMG LIKE RM61B-ERFMG,
P_MATNR LIKE RM61B-MATNR <b>VALUE CHECK</b> ,
Thank for all the time and help..
‎2006 Dec 12 5:18 PM
Hi,
I am not able to find the code that issues a message when the foreign key check fails..I also tried with system debugging..sorry..:-((
Thanks,
Naren