Example #1
0
        protected void Weekly()
        {
            TimeSpan threadWait = LastUpdate.Add(Duration) - LastUpdate;

            Thread.Sleep((int)threadWait.TotalMilliseconds);

            Duration   = new TimeSpan(7, 0, 0, 0, 0); // Add Seven Days, reached target day.
            LastUpdate = DateTime.Now;
        }