Beispiel #1
0
 /// <summary>
 /// Runs the application with errorlogger
 /// </summary>
 static void RunWithErrorLog()
 {
     try
     {
         Run();
     }
     catch (Exception e)
     {
         using (var errorLogger = new ErrorLogger(e))
         {
             errorLogger.Run();
         }
     }
 }
Beispiel #2
0
 /// <summary>
 /// Writes an exception to the log file
 /// </summary>
 /// <param name="ex"></param>
 public static void Log(Exception ex)
 {
     using (var logger = new ErrorLogger(ex))
         logger.Run();
 }