Hello Everyone,

Can we see the code execution step by step on an editor.

Am using

IBM Rational Software Development Platform

Version: 6.0.0
Build id: 20041117_2230

(c) Copyright IBM Corp. and others 2000, 2004. All rights reserved.


This product is powered by Eclipse technology. ( http://www.eclipse.org )

If it's Eclipse-based you just have to run your app in debug mode for full execution & variable tracing

Actually i have written a small program on division, now i want see the control flow means how the line of code is executing and calling the methods and function step by step.

But when am run the program in debug mode nothing is showing

Actually i have written a small program on division, now i want see the control flow means how the line of code is executing and calling the methods and function step by step.

But when am run the program in debug mode nothing is showing

You must first place a breakpoint. You place somewhere in your code and when you debug, the code runs up until that point and stops. You can then see all the values of the variables that have been initialized up to that point. Then you have some options where you can continue line by line and observe the code and the values.

To place a breakpoint in eclipse simply right click at the left side of the editor where the line numbers are.

Thanks for reply

Ok....

I can place breakpoints any where in code or only at specified place.

Regards,
Abrar.

Anywhere you want. Normally you put one at the place where you want to start tracing, eg on the first line of the main method.

I mostly debug in SpringSource (which is Eclipse based) so I'm just speaking about Eclipse and SpringSource here.

you can start debugging, jumpt to the next executed line, to the next executed line in the same class, to the next line you run over which has a breakpoint on it, ...
the different steps you choose by pushing f5-f6-f7-f8.

what exactly do you think debugging does?
but was it really necessary to revive this thread to ask that?

A simple editor will not know how to trace executing Java code. You need a Java IDE such as NetBEans or Eclipse.

my guess, by editor, he meant an IDE.