的Visual Studio 2015年突破上未处理的异常不工作 [英] Visual Studio 2015 break on unhandled exceptions not working

查看:968
本文介绍了的Visual Studio 2015年突破上未处理的异常不工作的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

曾经有一个特定的复选框关于取消处理的异常中断的Visual Studio。 2015年这已被删除(或移动的地方我找不到它)。所以,现在我的转化项目,如果我不能提供用户级异常处理程序不再破裂。我不想打破所有抛出异常,因为我处理特定的。只是,我无法提供具体的处理程序。

Visual studio used to have a specific checkbox to "Break on Un-handled exception". In 2015 this has been removed (or moved somewhere I cannot find it). So now my converted projects no longer break if I fail to provide a user-level exception handler. I don't want to break on all "thrown exceptions" because I handle specific ones. Just where I fail to provide a specific handler.

现在我的代码只是退出当前程序,并在下次调用堆栈位置,不好。

Right now my code simply exits the current procedure and continues execution at the next call stack location, NOT GOOD.

任何人知道如何得到这回在Visual Studio 2015年?我刚刚升级到Community Edition昨天。

Anyone know how to get this back in Visual Studio 2015? I just upgraded to the community edition yesterday.

欢呼声中,泰德

推荐答案

有一个名为在默认情况下,当你开始调试出现在右下方的窗格中异常设置新窗口。它拥有所有你所期望的选项。

There's a new window called "Exception Settings" that appears in the lower right pane by default when you begin debugging. It has all of the options you would expect.

您可以使用<大骨节病> CTRL + <大骨节病> ALT 要拿出来+ <大骨节病>电子

You can bring it up with CTRL+ALT+E

这可以让你摘樱桃哪些异常导致调试中断。

This allows you to cherry-pick which exceptions cause a break in the debugger.

关键,不过,是你还可以设置这些异常是否总是打破,或只有突破时,它是一个未处理的异常 - 但是设置这个是不是很直观

The key, though, is that you can also set whether these exceptions always break, or only break when it's an unhandled exception -- but setting this is not very intuitive.

您需要先勾选启用仅我的代码下的工具>选项>调试。

You will need to first check "Enable Just My Code" under Tools > Options > Debugging.

这则允许你用鼠标右键单击列标题(歇当新的例外设置窗口时抛出),并增加了其他操作栏,然后允许你设置每个异常为继续当用户代码未处理。

This then allows you to right-click the column header (Break When Thrown) in the new Exceptions Settings window, and add the "Additional Actions" column, which then allows you to set each exception as "Continue when unhandled in user code".

更多关于这个位置:

http://blogs.msdn.com /b/visualstudioalm/archive/2015/02/23/the-new-exception-settings-window-in-visual-studio-2015.aspx

这篇关于的Visual Studio 2015年突破上未处理的异常不工作的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆