Пример #1
0
        protected override void OnStop()
        {
            timer.AutoReset = false;

            timer.Enabled = false;
            ServiceLog.WriteLog("Daily Reporting service stopped");
        }
Пример #2
0
        private void SetTimer()
        {
            double inter = GetNextInterval();

            timer.Interval = inter;
            ServiceLog.WriteLog("got interval::" + inter);
            timer.Start();
            timer.Elapsed += new ElapsedEventHandler(ServiceTimer_Tick);
            ServiceLog.WriteLog("got elapsed");
        }
Пример #3
0
 protected override void OnStart(string[] args)
 {
     timer.AutoReset = true;
     timer.Enabled   = true;
     ServiceLog.WriteLog("Daily Reporting service started");
 }