Attaching or removing breakpoint actions
You can attach one or more breakpoint actions to a single breakpoint. For example, when the breakpoint is hit you could both log a message and play a sound. Actions are executed in the order they appear in the Actions for this breakpoint list.
To attach or remove a breakpoint action from a breakpoint:
- In the Breakpoints view, right-click the breakpoint, and select Properties.
- In the Properties for C/C++ Breakpoint dialog box, click Actions.
- In the Available actions list:
- Select an action and click Attach to link it to the breakpoint. Repeat as required.
- To add a new breakpoint action, click New.
- To edit the selected breakpoint action, click Edit.
- To delete the selected action, click Delete.
NOTE: Deleting a breakpoint action removes it from the workspace.
- In the Actions for this breakpoint list you can:
- Click Remove to delete the selected action from the list.
- Click Up to move the selected action up in the list.
- Click Down to move the selected action down in the list.
- Click OK.
Using breakpoints, watchpoints, and breakpoint actions