计时器
模板
private static System.Timers.Timer timer;
timer = new System.Timers.Timer();
timer.AutoRest = false;
timer.Interval = 1000;
timer.Elapsed += (s,e) =>
{
Console.WriteLine("Hello");
timber.Start();
}
timer.Start();
Console.ReadKey();
private static System.Timers.Timer timer;
timer = new System.Timers.Timer();
timer.AutoRest = false;
timer.Interval = 1000;
timer.Elapsed += (s,e) =>
{
Console.WriteLine("Hello");
timber.Start();
}
timer.Start();
Console.ReadKey();