简体   繁体   中英

Visual Studio 2010 Pro, not ending debug mode on application close

When I run my code within VS, when I enter certain methods, upon ending the application (closing the form) been debugged, VS does not end the debug session automatically forcing me to end it manually.

This doesn't always happen, the results are consistent with certain windows / classes loaded when the application is run within VS.

I want to know why this may be, I'm assuming its an indication of a file not been closed in my managed code or 'something' like that.

Why might this occur and how can I trace and fix it?

This would happen if your code keeps running after closing the window.

Pause the debugger after closing the window to find out what it's doing, then modify the code so that it stops running when you close the window.

On Debug menu, click "Detach All".

Hope that helps!

EDIT

Follow, SLak's advice, as that will go after the problem. My solution may only fix the symptom. I will leave the answer here just in case it is helpful to you though.

Good luck!

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM