07-08-2010 6:49 AM
Hi Experts,
Is it possible to skip serveral lines of coding when you're in debugging?
I mean completely skip the coding, not run the coding at all.
Regards,
Aaron
07-08-2010 7:24 AM
Hello,
It is possible to skip few stmts in the code while debugging. What you can do is, suppose you are at line 2 in the debugger and you want to skip line 3,4,5 and directly go to line 6. Keep the curosor at line 6 and in the menu choose Debugger -> Goto Statement. THen the execution control goes to line 6 without executing line 3,4,5.
Hope this helps!
Regards,
Srilatha
07-08-2010 7:08 AM
Hi,
You can set a breakpoint by setting a breakpoint at a function module or a statement to go to the code directly, wherever you want. Check the Menu path Breakpoint > Breakpoint at .
Hope it helps you.
07-08-2010 7:24 AM
Yes,
just highlight the line of code you want to go to and then select (from Debugger menu tab) Goto Statement - Shift+F12.
In this way you can jump over sections of code. You have to be using the new design debugger - Setting -> ABAP Editor -> debugging -> New Debugger.
not really a WDA specific question though!
Cheers!
07-08-2010 7:24 AM
Hello,
It is possible to skip few stmts in the code while debugging. What you can do is, suppose you are at line 2 in the debugger and you want to skip line 3,4,5 and directly go to line 6. Keep the curosor at line 6 and in the menu choose Debugger -> Goto Statement. THen the execution control goes to line 6 without executing line 3,4,5.
Hope this helps!
Regards,
Srilatha
07-08-2010 5:03 PM
Well, I Guess you mean to skip the actual execution of code, Not unless there is a way to comment out the code in debugging. So the the Answer is 'NO'
07-08-2010 6:15 PM
Ramesh Kumar Pampapathi, did you read the previous answer from Srilatha? who says yes and explains how to do it (and he's right)
07-08-2010 7:30 PM
Chris Paine:
The Debugging --> Goto Statement option is also available in the old debugger. We have it here in release 4.7
.. Craig
07-08-2010 11:05 PM
There are two ways to look at this question
1) In debugging, developer wants to skip the lines of code and jump directly to the other lines. Yes, this is possible as mentioned by everyone above. Saves a lot of time and less stress
2) Ramesh says no to the fact that we cannot avoid the processing of any code in debugging. Which is also correct.
Example this code snippet.
l_variable1 = l_variable2 + l_variable3
if l_variable1 GT 0.
do some logic
endif.
During debugging, if i do not want l_variable1 to take the value of l_variable2+l_variable3. This cannot be avoided from
happening.
07-09-2010 2:39 AM
Sandeep and Ramesh,
The point 2 can be done as mentioned by srilatha.
I tried it myself. It ignores the actual processing of the lines in between.
Try it yourself and see.
So the answer is YES