using System.Diagnostics; EventLog.WriteEntry("Error Title", exp.Message, System.Diagnostics.EventLogEntryType.Error);