摘要:
共有两种方法:一。使用TimerGlobal.asax.cs代码:引入命名空间:System.IO;protected void Application_Start(object sender, EventArgs e){System.Timers.Timer myTimer = new System.Timers.Timer(10000);myTimer.Elapsed += new System.Timers.ElapsedEventHandler(OnTimedEvent);myTimer.Interval = 10000;myTimer.Enabled = true;}private 阅读全文