Failed to disable debugger while approving

Is there a way to break the debugger when the statement is false and start the application using the Visual Studio debugger. Previously, when I was debugging a Windows application, I received an exception and the debugger was interrupted, but now on the Smart Device a window with a confirmation error with a stack trace is shown, but I would also like to see the values โ€‹โ€‹of variables, etc.

+7
source share
4 answers

Stupid of me, the decision was simple. When the window pops up, click pause in the debugger :)

+11
source

Not sure about VS 2008, but at least in 2010 and later you can go to Debug / Exceptions (Ctrl-Alt-E). Click the Add button, select General Language Runtime Exceptions, and enter:

Microsoft.VisualStudio.TestTools.UnitTesting.AssertFailedException 

and click OK. Now it will appear in the list, make sure you check the box in the "Abandoned" column. Now you will receive a break in any denial.

+8
source

In addition to the Vinay solution, you can run a debugger for a specific process by calling

Debugger.Break

In your case, you can do this every time the listener receives an error message.

+4
source

It seems you can attach a debugger when the statement does not see other details - see this article: http://blogs.msdn.com/b/davidklinems/archive/2005/08/29/457847.aspx . Its quite outdated, but perhaps still applicable.

+1
source

All Articles