Esempio n. 1
0
        public static void LogException(Exception ex)
        {
            using (ReportWatchEntities entities = new ReportWatchEntities())
            {
                ExceptionLog entry = entities.ExceptionLogSet.CreateObject();
                entry.ExceptionLogId = Guid.NewGuid();
                entry.ExceptionLogDate = DateTime.Now;
                entry.ExceptionLogMessage = ex.Message;
                entry.ExceptionLogStackTrace = ex.StackTrace;
                entities.ExceptionLogSet.AddObject(entry);

                entities.SaveChanges();
            }
        }
Esempio n. 2
0
 public SymbolProcessor(DateTime reportDate)
 {
     _entities = new ReportWatchEntities();
     this._reportDate = reportDate;
 }