Exemple #1
0
 // Used to test MailMonitor
 // Quit if any keys are pressed
 // or write any trown exeptions to the command line.
 static void Main()
 {
     try
     {
         NewMail MailMonitor = new NewMail();
         MailMonitor.Start();
         Console.WriteLine("Hit return to exit");
         Console.ReadLine();
         MailMonitor.Stop();
     }
     catch (Exception ex)
     {
         Console.WriteLine(ex.Message);
     }
 }
Exemple #2
0
 protected override void OnStart(string[] args)
 {
     MailMonitor = new NewMail();
     //eventLog.WriteEntry("OnStart");
     MailMonitor.Start();
 }