You can control program execution in the Debugger using the following commands and procedures, all of which are available from the Run and Debug menus.

Method

Type of program execution control

Run

Runs the program, stopping at each error to display an error message. The line after the offending line is highlighted in blue.

Stop

Stops execution of the program.

Run To Cursor

Executes lines from the current position to the cursor location and stops there.

Step Over

Skips subroutines (any called functions, methods, or procedures).

Step Into

Shows line-by-line execution of subroutines, stopping at the end of each subroutine. You can step into another nested subroutine.

Step Out

Returns display of line-by-line execution to the preceding level of the program.

Break on next executable line

Causes program execution to stop at the next executable line, regardless of where execution starts.

Using breakpoints

Breakpoints are specific points in the program that you set to stop execution, letting you assess the situation. You can isolate a section of code for closer study by placing a breakpoint at the beginning and end of the section, then running that section repeatedly. You can further subdivide the section by adding more breakpoints.

Watching variables

You can see the current real-time value of any variable by holding the cursor over it. You can select particular variables (from the Variable tool window which shows all the variables in the program) and watch how their values change in the Watch tool window.