Order in Chaos: Handling unhandled exceptions in a WPF application

added by arikp
8/28/2011 6:37:19 PM

217 Views

Introduction So you want to handle somehow all the unhandled exceptions in your application. Usually you want to accomplish one of the following:Log the exception for later diagnostics Present the user an unhandled exception UI, nicer than the default You heard there’s an event you should register, or maybe you find one by mistake, but is it the correct one? Did you know there are four (!) different events for handling exceptions?


2 comments

dpeterson
8/28/2011 6:36:29 PM
Seems like a nice catch-all for handling exceptions that have been missed somewhere. In production, it would be a good tool to help track down code not covered by exception handling.
I don't think this code should be relied upon for all your error-handling needs however ;-)

vijayst
8/28/2011 11:42:41 PM
It was interesting reading your article. We look forward to similar articles in WPF.