Simon Mourier's Avatar
Simon Mourier's blog (1807 answers on StackOverflow) about Microsoft technologies C#, C/C++, .NET, WinRT, WinUI3, AOT, P/Invoke, COM, Interop, DirectX, Direct2D, Windows, ...
  • 🔎︎ Search
  • Categories
  • Archives
  • About Me
  • c#
  • debugging

c# force debug mode programmatically

Sep 18, 2011 See the question and my original answer on StackOverflow

Debugger.Launch will launch a debugger or will do nothing is one is already attached. I believe It's not a breakpoint. Debugger.Break() will actually break.

Calling Debugger.Launch() may do different things depending on the machine, for example if Visual Studio is installed or not, etc.

See also a related tech article: How to: Launch the Debugger Automatically

  • SmoBlog © 2010-2026 Simon Mourier. All rights reserved.
  • Privacy & Terms