For unhandled exceptions, at least, I\'d like to be able to catch the details and write them out to a file for potential subsequent \"debugging forensics.\" There is no \"On
For HTML5/JavaScript apps you have the onerror event as your last chance to capture info.
For XAML-based apps, you can use UnhandledException; however, that only captures exceptions that come up through the XAML (UI) framework and you don't always get a lot of information about what the root cause is, even in InnerException.
Update for Windows 8.1: UnhandledException also will capture exceptions that are created by an async void method. In Windows 8, such exceptions would just crash the app. LunarFrog has a good discussion of this on their website.