2

I've a WPF application which runs globally fine. But sometimes, the client tell me that he gots some crashes. But I've no information about what happened except what he does.

Is there a way to put a global try{}catch(Exception){LOGEXCEPTION; throw;} somewhere to receive all exceptions generated by a GUI action, or any other option.

Something like a "Last remedy" to log exception that we didn't manage well?

Thank you!

1 Answer 1

2

By handling the following events, you should be able to catch the vast majority (if not all) unhandled exceptions in your application:

  • Application.DispatcherUnhandledException
  • AppDomain.CurrentDomain.UnhandledException

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.