private static void Application_ThreadException(object sender, System.Threading.ThreadExceptionEventArgs e)
 {
     SettingsReader.LogException(e.Exception);
 }
 private static void CurrentDomain_UnhandledException(object sender, UnhandledExceptionEventArgs e)
 {
     SettingsReader.LogException((Exception)e.ExceptionObject);
 }