Suspending, Resuming, and Terminating Threads (Integrated Debugger)

When one or more programs are running, the Debug page in the Debugger browser shows all running threads, grouped by program.  You can suspend, resume, and terminate the threads as needed. 

Suspending a Running Thread
To examine a thread at any point while it is running, you must suspend it manually.   Then you can modify or step through its methods and inspect its variables.

To suspend a thread manually:

  1. Open the Debugger browser.
  2. Select the thread in the All Programs/Threads pane in the Debug page.
  3. Click the Suspend button suspend.gif (1037 bytes) in the toolbar.

Threads halted because of a breakpoint or uncaught exception are suspended automatically.

Once a thread is suspended, expand it in the All Programs/Threads pane to view its method stack.  Select a method to inspect its visible variables or work with its code.  In the source pane, you can see how the current value of a variable is being calculated by holding the mouse pointer (I-bar) over the variable in the source.   After about a second, a pop-up dialog will appear, showing the information.

Resuming Running a Thread
When a thread has been suspended, either by the manual method above, or automatically when the Debugger opens for a break point or uncaught exception, you can resume running the suspended thread.  It will run until suspended manually or automatically, or until the thread terminates.

To resume running a thread:

  1. Select the suspended thread.
  2. Click the Resume button resume.gif (1020 bytes) on the toolbar.

The running is resumed at the point it left off, unless one of the following things has been done while the thread was suspended:

The program will continue running until it is suspended again or until it terminates.

Note: You can not resume running after an uncaught exception.

Terminating a Thread
When you terminate a thread, it is removed from the Debugger browser and cannot be suspended or resumed.  Often, terminating a thread will stop the running of the program.  To terminate a thread:

  1. Select the thread in the All Programs/Threads pane of the Debug page.
  2. Click the Terminate button terminate.gif (1022 bytes) on the toolbar.

The thread will terminate.  To restart the thread, you must restart the program from the beginning.

Alternative Methods of Suspending, Resuming, and Terminating
Besides using the toolbar buttons described above, you can select Suspend, Resume, and Terminate menu options from the Selected menu or the pop-up menu for a thread.  Also, pressing F8 resumes a suspended thread.

ngrelc.gif (533 bytes)
The Integrated Debugger

ngrelt.gif (466 bytes)
Debugging During the Development Cycle
Opening the Debugger Manually
Setting Breakpoints in Source Code
Inspecting and Modifying Variable Values
Stepping Through Methods
Modifying Code while Debugging