Enabling and disabling breakpoints

Rather than deleting a breakpoint, you can disable it so that it does not stop program execution.

About this task

When you disable a breakpoint, it remains in the Breakpoints view. To have your program stop on a breakpoint that you have disabled, select and enable it. The advantage of disabling a breakpoint instead of deleting it is that you do not have to find the location in the source to set the breakpoint again. In addition, a disabled breakpoint saves any extra settings (such as type, location, condition, and frequency) that you may have made to the breakpoint.

Disabled breakpoints are indicated with a clear dot, while enabled breakpoints are indicated with a filled dot. When a breakpoint is disabled, you can choose Enable from its pop-up menu, and the Disable menu item is not available. When a breakpoint is enabled, you can choose Disable from its pop-up menu and not Enable.

You can enable or disable a single breakpoint from the Breakpoints view, as follows:

Procedure

  1. Click on the Breakpoints view to bring it to the foreground.
  2. Scroll the list of breakpoints until you see the breakpoint you want to enable or disable.
  3. Right-click on the breakpoint you want to enable or disable.
  4. Select Enable or Disable from the pop-up menu.

Results

You can enable or disable a single line breakpoint from the editor, as follows:

  1. In the editor marker bar, locate the breakpoint that you want to disable.
  2. From the breakpoint's pop-up menu in the editor or from the breakpoint's pop-up menu in the marker bar, select Enable Breakpoint if it is disabled or Disable Breakpoint if it is enabled.
  3. The breakpoint indicator changes, indicating that it is enabled or disabled.

Feedback