Tracing Execution

After your program has been paused, you need to see what's going wrong with your code. This can mean watching your code run line by line (tracing) to see where, for example, it takes a different path through a decision structure than what you expected.

The following tools are available when tracing code:

• The F8 key steps into a procedure, which is the most detailed mode of tracing. If the procedure you're tracing makes a call to another procedure, execution transfers to the called procedure just as it would normally, but in break mode.

• After you've stepped into a procedure and have decided that you no longer need to trace through it, you can step out (Ctrl+Shift+F8) to return to the calling procedure.

• Stepping over (Shift+F8) is to treat a call to another procedure as a stand-alone statement; that is, to trace the code that calls another procedure without actually tracing the h code in the called procedure. is a.

• Using the Run To Cursor option (Ctrl+F8) essentially creates a temporary break- J2 point. Code runs from the current location to the cursor, where it re-enters ° break mode. This is useful if you stepped into a procedure and want to skip over large sections of it without stepping out of it, but don't want to create an actual breakpoint.

Note Pressing F5 while tracing execution returns to normal execution, unless another breakpoint is encountered before the program ends.

Project Management Made Easy

Project Management Made Easy

What you need to know about… Project Management Made Easy! Project management consists of more than just a large building project and can encompass small projects as well. No matter what the size of your project, you need to have some sort of project management. How you manage your project has everything to do with its outcome.

Get My Free Ebook

Post a comment