/// <summary> /// Runs the application with errorlogger /// </summary> static void RunWithErrorLog() { try { Run(); } catch (Exception e) { using (var errorLogger = new ErrorLogger(e)) { errorLogger.Run(); } } }
/// <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(); }