Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

ASP debugging - hit breakpoint then abort current request's execution

I am debugging an ASP page with visual studio 2013.

So, i set a breakpoint, the breakpoint gets hit, and the execution gets on hold.

Now, i just want to abort the current request stop executing the code for the current request (which is on hold as it had hit the breakpoint), without having to stop debugging and run again the project.

This seems too simple, yet i haven't figured out how to do it.

Let me explicity state that clicking "restart" is not what i need, as "restart" is just a shortcut to stop project and run again.

like image 666
Sharky Avatar asked Jun 17 '16 08:06

Sharky


People also ask

Why is my breakpoint not being hit?

If a source file has changed and the source no longer matches the code you're debugging, the debugger won't set breakpoints in the code by default. Normally, this problem happens when a source file is changed, but the source code wasn't rebuilt. To fix this issue, rebuild the project.

Why is Visual Studio not stopping at the breakpoints?

This problem occurs because ASP.NET debugging isn't enabled on the application.


Video Answer


1 Answers

Based on our conversation in the comments, I am placing this as an answer.

What you are asking for is not part of the visual studio debugging process. unless you manually return from the request after the break point the process is going to continue running. When debugging you are just an observer of the process. Either the code kills the process via exception or returns from execution, or you kill the process externally.

It does not looks like what you are asking for is possible, and that is by design.

like image 87
Nkosi Avatar answered Sep 19 '22 16:09

Nkosi