public EmailQueueProcessorService()
 {
     InitializeComponent();
     ((System.ComponentModel.ISupportInitialize)(EventLog)).BeginInit();
     EventLog.Source = "EmailQueueProcessorServiceLogSource";
     EventLog.Log = "EmailQueueProcessorServiceLog";
     ((System.ComponentModel.ISupportInitialize)(EventLog)).EndInit();
     if (!System.Diagnostics.EventLog.SourceExists("EmailQueueProcessorServiceLogSource"))
     {
         System.Diagnostics.EventLog.CreateEventSource("EmailQueueProcessorServiceLogSource", "EmailQueueProcessorServiceLog");
     }
     EmailQueueProcessor = new EmailQueueProcessor();
     Timer = new Timer(Process, null, 2, 1000 * 60 * EmailQueueProcessor.ProcessorSettings.SleepTime);
 }
Example #2
0
 static void Main(string[] args)
 {
     EmailQueueProcessor emailQueueProcessor = new EmailQueueProcessor();
     emailQueueProcessor.ProcessQueue();
 }