简体   繁体   中英

Visual Studio 2015 throw exception in Try Catch block

Visual Studio 2015 always throw exception in debug mode, even if error is handled in Try Catch block, which is very annoying. Could You tell me why is this happening? I dont know how to switch this off..

Go to Exception Settings ( Ctrl + Alt + E on my visual studio) and tick or untick the kind of exception you want to break on when they are thrown.

Edit explanation When you run in debug mode, Visual Studio believe that notifying when an exception is raised is a good way to help the developper. Even if the exception is caught. The Exception Settings allows you to change this behaviour by choosing what the kind of exception should be notified or not.

You have enabled first chance exception handling.

To disable it open Debug->Windows->Exception Settings and uncheck the exceptions you don't want to break the debugging when thrown. Check the link for more details.

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