views:

14

answers:

1

In NetBeans when you insert Breakpoint and Debug project, it runs code until the Breakpoint and stop right in a line where we put Breakpoint. And afterwards we can execute our code step by step. If we Press F8 which is Step Over operation, NetBeans executes next line. Sometimes we want to go back to the previous executed line because we want to change that line and see how it will work.
So, the question is how can I say NetBeans to Step Back (if we can call this like this), so instead of executing next line code it executes previous line code? I remember in Visual Basic 6.0 (now I don't know because don' t use it anymore) we could manage current execution line, i.e. we could just drag and drop debug pointer to the line we want during the debugging and it would start to execute code right from the place we put it. Is it possible in NetBeans?

Update 1
I use NetBeans for debugging PHP application. PHP uses php_xdebug-2.1.0RC1-5.3-vc9-nts.dll to to debug PHP code.

A: 

It's not only a matter of Netbeans (or to say it more generally: your IDE), it's also a matter of the debug capabilities of your jvm. AFAIK, no jvm does currently have this feature.

What might be possible (in Eclipse it is) is to step to the beginning of the method, but you have to be careful about the state of your objects, because you may reach a state which you won't within a normal execution.

MRalwasser