Debugger2::Break Method (Boolean)
Visual Studio 2015
Causes the given process to pause its execution so that its current state can be analyzed.
Assembly: EnvDTE80 (in EnvDTE80.dll)
Parameters
- WaitForBreakMode
-
Type:
System::Boolean
Set to true to return only when the debugger has entered break mode. Set to false to break and return immediately. See How to: Break Execution for more information.
Implements
Debugger::Break(Boolean)Causes the given process to pause its execution so that its current state can be analyzed.
The following example demonstrates how to use the Break method.
public static void Break(EnvDTE80.DTE2 dte) { // Setup debug Output window. Window w = (Window)dte.Windows.Item(EnvDTE.Constants.vsWindowKindOutput); w.Visible = true; OutputWindow ow = (OutputWindow)w.Object; OutputWindowPane owp = ow.OutputWindowPanes.Add("Break Method Test"); owp.Activate(); EnvDTE80.Debugger2 debugger = (EnvDTE80.Debugger2)dte.Debugger; debugger.Break(false); owp.OutputString("The process is paused. Examine the values of variables."); }
Show: