Halting a running program

If the application that you are debugging is running, you can halt it by suspending thread execution. When you are debugging an application and you choose to suspend thread execution, the thread will suspend at the first possible statement (typically, thread execution only occurs after certain scripts have been run - so you can only issue a suspend action at that time). When you issue a suspend action, the thread remains suspended until you until you issue a Resume action.

When you are debugging JSP pages that generate script or forms in HTML and you want to suspend execution for that script, you need to issue a suspend action on the thread before launching the script action. If you do not suspend the thread, the debugger will not stop within that action.

To suspend an executing thread, complete these steps:

  1. In the Debug view, select the thread or the connection node associated with it.
  2. Perform one of the following tasks:
    • Click Suspend ( Suspend icon) in the Debug view toolbar.
    • Right-click and select Suspend from the pop-up menu.

If you run script in the browser being debugged, the application will halt at the first possible statement. When the application is halted, the current line of execution will be highlighted in the editor.

To resume a suspended thread, complete these steps:

  1. Select the thread, one of its stack frames, or the connection node associated with it.
  2. Perform one of the following tasks:
    • Click Resume ( Resume icon) in the Debug view toolbar.
    • Right-click and select Resume from the pop-up menu.
    • Press F8.

The thread will resume execution, and stack frames will no longer be displayed for the thread.

Related tasks
Using the Debug view
Debugging an HTML Script Application
Debugging a Script Host Application
Running an Active Script application
Stepping through a program
Terminating a debug session
Starting a debug session with an existing launch configuration
Editing launch configurations
Removing launch configurations
Creating new launch configurations from existing launch configurations
Debugging Web project script
Debug on Server
Setting debug preferences
Editing and viewing source while debugging
Using breakpoints
Setting a line breakpoint
Enabling and disabling breakpoints
Removing breakpoints
Terms of use | Feedback
(C) Copyright IBM Corporation 2003, 2005. All Rights Reserved.