Пример #1
0
 protected void OnTimeElapsed(int counter)
 {
     if (TimeElapsed != null)
     {
         TimeElapsedEventArgs e = new TimeElapsedEventArgs(counter);
         TimeElapsed(this, e);
     }
 }
Пример #2
0
 public static void TimerPrinting(object sender, TimeElapsedEventArgs e)
 {
     Console.WriteLine("I am delegate and print myself at some interval");
 }