开发者

Get the Crash Info from user[.NET]

When my application crashed, I want to get the crash infomatin from the user,so i wander how to get the crash info from the user?And how to handle the exceptions when th开发者_开发问答e main application crashed?

ps.Just like that window:"Would you like to send the crash info to Microsoft?"


What you need to do is catch all uncaught exceptions for the application.

The AppDomain.CurrentDomain.UnhandledException event handler allows you to add an event handler for all uncaught exceptions. With the exception you receive with this event, you can show the dialog you want.

See articles like Why is .NET exception not caught by try/catch block? on how to catch all exceptions.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜