Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- // handle UI thread exceptions
- Application.ThreadException += Application_ThreadException;
- // handle non-UI thread exceptions
- AppDomain.CurrentDomain.UnhandledException += CurrentDomain_UnhandledException;
- Application.EnableVisualStyles();
- Application.SetCompatibleTextRenderingDefault(false);
- // force all windows forms errors to go through our handler
- Application.SetUnhandledExceptionMode(UnhandledExceptionMode.CatchException);
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement