Simple Task Scheduler inside your application (C#)

 

Many times I need a simple task scheduler inside a program to do this or that. You can use any of the system timers to achieve this, but you end up writing the same difficult code over and over. This simple scheduler is built to be simple and efficient. There is no interval "period" (i.e. system Timer) to worry about or set. If you need to reschedule a Task, just reschedule it at the end of your task delegate. That way, you don’t have to worry about strange recursive overlaps. In a perfect world, I just would return a Task (in the pfx library), but you can’t schedule a pfx.Task to run in the future. It is started during construction, so I could not return a Task. Instead I created something similar and named it TimerTask.

TimerScheduler is a static class that has 2 simple static methods – Add and Remove.  The Add() method will schedule a delegate (can use lambda syntax) at any point in the future and immediately return a TimerTask object to represent the task. The TimerTask can be canceled if it has not run yet. The Remove() method will un-schedule any task if it has not been started.  The scheduler works similar to System.Threading.Timer in that it adds Tasks to a list sorted by run times. Only one internal thread schedules tasks, each on a thread pool thread. The scheduler thread will block (i.e. do nothing) if no tasks are ready to run or the list is empty so it is efficient.  Any number of tasks can be scheduled to the limits of resources and max list size.  The only resources used for all waiting tasks is the object allocations and the single scheduler thread.

Hope it finds a way in a program or two.

–William

public static class TestTaskScheduler
{
    public static void Test1()
    {
        TimerTask tt = TaskScheduler.Add(DateTime.Now, () =>  Debug.WriteLine("Task1 done."));

        TimerTask tt2 = null;
        tt2 = TaskScheduler.Add(5000, () =>
        {
            Debug.WriteLine("Task2 done.");
            string ss = string.Format("Task:{0} RunDate:{1}", tt2.Completed, tt2.RunDate);
            Debug.WriteLine(ss);
        });
    }
}

public class TimerTask
{
    internal int completed;
    internal Exception exception;
    private readonly Action action;
    private readonly DateTime runDate;

    internal TimerTask(Action action, DateTime runDate)
    {
        this.action = action;
        this.runDate = runDate;
    }

    public bool Completed
    {
        get { return completed == 1; }
    }

    public DateTime RunDate
    {
        get { return this.runDate; }
    }

    public Exception Exception
    {
        get { return this.exception; }
    }

    public bool Cancel()
    {
        return TaskScheduler.Remove(this);
    }

    internal Action Action
    {
        get { return this.action; }
    }
}

/// <summary>
/// Schedules Tasks to run at future time.
/// </summary>
public static class TaskScheduler
{
    /// <summary>
    /// The maximum lag time allowed. RunAt times less then this value are not allowed.
    /// </summary>
    public static readonly TimeSpan MaxPassed;
    private static readonly object sync;
    private static Thread mt;
    private static SortedList<DateTime, TimerTask> sl;

    static TaskScheduler()
    {
        MaxPassed = TimeSpan.FromSeconds(-5);
        sync = new object();
        sl = new SortedList<DateTime, TimerTask>();
        mt = new Thread(Scheduler);
        mt.Name = "NewTimerScheduler";
        mt.IsBackground = true;
        mt.Start();
    }

    /// <summary>
    /// Schedule a Task to run at specified time.
    /// </summary>
    /// <param name="runAt"></param>
    /// <param name="action"></param>
    /// <returns></returns>
    public static TimerTask Add(TimeSpan runAt, Action action)
    {
        DateTime dt = DateTime.Now.Add(runAt);
        return Add(dt, action);
    }

    /// <summary>
    /// Schedule a Task to run at specified time.
    /// </summary>
    /// <param name="milliseconds"></param>
    /// <param name="action"></param>
    /// <returns></returns>
    public static TimerTask Add(double milliseconds, Action action)
    {
        DateTime dt = DateTime.Now.AddMilliseconds(milliseconds);
        return Add(dt, action);
    }

    /// <summary>
    /// Schedule a Task to run at specified time.
    /// </summary>
    /// <param name="runAt"></param>
    /// <param name="action"></param>
    /// <returns></returns>
    public static TimerTask Add(DateTime runAt, Action action)
    {
        if (action == null)
            throw new ArgumentNullException("action");
        if ((runAt – DateTime.Now) < MaxPassed)
            throw new InvalidOperationException("runAT is too far in the past.");

        TimerTask to = new TimerTask(action, runAt);

        lock (sync)
        {
            sl.Add(to.RunDate, to);
            Monitor.Pulse(sync);
            return to;
        }
    }

    /// <summary>
    /// Remove a TimerTask.
    /// </summary>
    /// <param name="timerTask">The TimerTask that was scheduled.</param>
    /// <returns>true if TimerTask has not been scheduled yet; otherwise false.</returns>
    public static bool Remove(TimerTask timerTask)
    {
        if (timerTask == null)
            throw new ArgumentNullException("timerTask");

        lock (sync)
        {
            int index = sl.IndexOfValue(timerTask);
            if (index > -1)
            {
                sl.RemoveAt(index);
                Interlocked.Exchange(ref timerTask.completed, 1);
                return true;
            }
            return false;
        }
    }

    /// <summary>
    /// Main scheduler thread. One thread is used to schedule queued tasks.
    /// Tasks are run on a ThreadPool thread when there start time triggers.
    /// </summary>
    private static void Scheduler()
    {
        lock (sync)
        {
            while (true)
            {
                while (sl.Count == 0)
                    Monitor.Wait(sync);

                TimerTask first = sl.Values[0];

                // If first has been canceled, remove it without running.
                if (first.Completed)
                {
                    sl.RemoveAt(0);
                    continue;
                }

                // If time for first task to run, run it on a ThreadPool thread.
                if (first.RunDate <= DateTime.Now)
                {
                    // Run task on thread pool thread.
                    sl.RemoveAt(0);
                    ThreadPool.QueueUserWorkItem(delegate(object obj)
                        {
                            try
                            {
                                first.Action(); // Exec user task delegate.
                            }
                            catch(Exception ex)
                            {
                                Interlocked.Exchange<Exception>(ref first.exception, ex);
                            }
                            Interlocked.Exchange(ref first.completed, 1);
                        });
                    continue;   // Start over.
                }

                // No task is ready to run, so wait for timespan.
                TimeSpan waitTill = first.RunDate – DateTime.Now;
                if (waitTill.Milliseconds <= 0)
                    continue;   // Run it now.
                Monitor.Wait(sync, waitTill);
            }
        }
    }
}

Advertisements
This entry was posted in Uncategorized. Bookmark the permalink.

16 Responses to Simple Task Scheduler inside your application (C#)

  1. Unknown says:

    http://www.batteryfast.co.uk/laptop-ac-adapter/dell/dell-19.5V-6.7A-130w-7.4mm-5.0mm-with-pin-pa-13.php Dell 19.5V 6.7A 130W 7.4MM*5.0MM Adapter http://www.batteryfast.co.uk/laptop-ac-adapter/liteon/liteon-20V-6A-120w-4-pin.php Liteon 5600P 5620 20V 6A 120W 4 PIN Adapter http://www.batteryfast.co.uk/laptop-ac-adapter/liteon/liteon-20V-6A-120w-5.5mm-2.5mm.php Liteon 1520 1500 NX9100 20V 6A 120W 5.5MM*2.5MM Adapter http://www.batteryfast.co.uk/laptop-ac-adapter/samsung/samsung-19V-3.16A-60w-5.5mm-3.4mm-pin-inside.php Samsung GT8000 GT8600 19V 3.16A 60W 5.5MM*3.4MM Adapter http://www.batteryfast.co.uk/laptop-ac-adapter/samsung/samsung-19V-4.74A-90w-5.5mm-3.0mm.php Samsung M50 X60 19V 4.74A 90W 5.5MM*3.0MM Adapter http://www.batteryfast.co.uk/laptop-ac-adapter/delta/delta-19V-4.74A-90w-5.5mm-2.5mm.php Delta 19V 4.74A 90W 5.5MM*2.5MM Adapter http://www.batteryfast.co.uk/laptop-ac-adapter/acer/acer-19V-7.1A-135w-5.5mm-2.5mm.php Acer Aspire 1520 1620 19V 7.1A 135W 5.5MM*2.5MM Adapter http://www.batteryfast.co.uk/laptop-ac-adapter/compaq/compaq-18.5V-2.7A-50w-4.8mm-1.7mm.php Compaq NC6000 NC8000 18.5V 2.7A 50W 4.8MM*1.7MM Adapter http://www.batteryfast.co.uk/laptop-ac-adapter/compaq/compaq-18.5V-6.5A-120w-5.5mm-2.5mm.php Compaq R3000 NX9100 18.5V 6.5A 120W 5.5MM*2.5MM Adapter http://www.batteryfast.co.uk/laptop-ac-adapter/compaq/compaq-19V-4.74A-90w-5.5mm-2.5mm.php Compaq NX9000 DV9000 19V 4.74A 90W 5.5MM*2.5MM Adapter http://www.batteryfast.co.uk/laptop-ac-adapter/fujitsu/fujitsu-19V-3.16A-60w-5.5mm-2.5mm.php Fujitsu A4190 S7000 19V 3.16A 60W 5.5MM*2.5MM Adapter http://www.batteryfast.co.uk/laptop-ac-adapter/hp/hp-18.5V-4.9A-90w-5.5mm-2.5mm.php Hp ZT1000 XT1000 18.5V 4.9A 90W 5.5MM*2.5MM Adapter http://www.batteryfast.co.uk/laptop-ac-adapter/hp/hp-18.5V-6.5A-120w-5.5mm-2.5mm.php Hp ZV5000 ZX5001 18.5V 6.5A 120W 5.5MM*2.5MM Adapter http://www.batteryfast.co.uk/laptop-ac-adapter/hp/hp-18.5V-6.5A-120w-flat-dc.php Hp NX9600 ZD8000 18.5V 6.5A 120W FlAT DC Adapter http://www.batteryfast.co.uk/laptop-ac-adapter/ibm/ibm-16V-4.5A-60w-5.5mm-2.5mm.php Ibm T40 X30 R30 16V 3.5A 56W 5.5MM*2.5MM Adapter http://www.batteryfast.co.uk/laptop-ac-adapter/ibm/ibm-20V-3.25A-65w-7.9mm-5.5mm-DC-with-pin-inside.php Ibm Z60M X60 2530 20V 3.25A 65W 7.9MM*5.5MM Adapter http://www.batteryfast.co.uk/laptop-ac-adapter/liteon/liteon-19V-3.95A-75w-5.5mm-2.5mm.php Liteon 1200 1800 19V 3.95A 75W 5.5MM*2.5MM Adapter http://www.batteryfast.co.uk/laptop-ac-adapter/liteon/liteon-19V-3.16A-60w-5.5mm-2.5mm.php Liteon Aspire 1200 19V 3.16A 60W 5.5MM*2.5MM Adapter http://www.batteryfast.co.uk/laptop-ac-adapter/sony/sony-16V-4A-65w-6.5mm-4.4mm.php Sony PCG-505 Series 16V 4A 65W 6.5MM*4.4MM Adapter http://www.batteryfast.co.uk/laptop-ac-adapter/sony/sony-19.5V-4.7A-90w-6.5mm-4.4mm.php Sony VGN-FS500 19.5V 4.7A 90W 6.5MM*4.4MM Adapter http://www.batteryfast.co.uk/laptop-ac-adapter/toshiba/toshiba-15V-3A-45w-6.3mm-3.0mm.php Toshiba PA2450U PA3241U-1ACA 15V 3A 45W 6.3MM*3.0MM Adapter http://www.batteryfast.co.uk/laptop-ac-adapter/toshiba/toshiba-15V-4A-60w-6.3mm-3.0mm.php Toshiba PA3092U-1AC PA2444U 15V 4A 60W 6.3MM*3.0MM Adapter http://www.batteryfast.co.uk/laptop-ac-adapter/toshiba/toshiba-15V-6A-90w-6.3mm-3.0mm.php Toshiba PA2521U PA3201U-1ACA 15V 6A 90W 6.3MM*3.0MM Adapter http://www.batteryfast.co.uk/laptop-ac-adapter/toshiba/toshiba-15V-8A-120w-special-4-hole.php Toshiba PA3237U 15V 8A 120W SPECIAl 4 HOlE Adapter http://www.batteryfast.co.uk/laptop-ac-adapter/toshiba/toshiba-19V-3.42A-65w-5.5mm-2.5mm.php Toshiba PA3467U PA3396U 19V 3.42A 65W 5.5MM*2.5MM Adapter http://www.batteryfast.co.uk/laptop-ac-adapter/toshiba/toshiba-19V-6.3A-120w-6.3mm-3.0mm.php Toshiba PA3336U PA3290U 19V 6.3A 120W 6.3MM*3.0MM Adapter

  2. Unknown says:

    http://www.batteryfast.com.au/toshiba/pa3395u-1brs.htm Toshiba pa3395u-1brs Batteryhttp://www.batteryfast.com.au/toshiba/pa3399u-2brs.htm Toshiba pa3399u-2brs Batteryhttp://www.batteryfast.com.au/toshiba/pa3420u.htm Toshiba pa3420u Batteryhttp://www.batteryfast.com.au/toshiba/pa3421u-1brs.htm Toshiba pa3421u-1brs Batteryhttp://www.batteryfast.com.au/toshiba/pa3451u.htm Toshiba pa3451u Batteryhttp://www.batteryfast.com.au/toshiba/pa3456u-1brs.htm Toshiba pa3456u-1brs Batteryhttp://www.batteryfast.com.au/toshiba/pa3465u-1brs.htm Toshiba pa3465u-1brs Batteryhttp://www.batteryfast.com.au/toshiba/pa3479u-1brs.htm Toshiba pa3479u-1brs Batteryhttp://www.batteryfast.com.au/toshiba/pa3480u-1brs.htm Toshiba pa3480u-1brs Batteryhttp://www.batteryfast.com.au/toshiba/pa3593u-1bas.htm Toshiba pa3593u-1bas Batteryhttp://www.batteryfast.com.au/toshiba/pa3594u-1brs.htm Toshiba pa3594u-1brs Batteryhttp://www.batteryfast.com.au/toshiba/satellite-a105.htm Toshiba satellite a105 Batteryhttp://www.batteryfast.com.au/toshiba/satellite-a205.htm Toshiba satellite a205 Batteryhttp://www.batteryfast.com.au/toshiba/satellite-a55.htm Toshiba satellite a55 Batteryhttp://www.batteryfast.com.au/toshiba/satellite-a70.htm Toshiba satellite a70 Batteryhttp://www.batteryfast.com.au/toshiba/satellite-l10.htm Toshiba satellite l10 Batteryhttp://www.batteryfast.com.au/toshiba/satellite-l100.htm Toshiba satellite l100 Batteryhttp://www.batteryfast.com.au/toshiba/satellite-l15.htm Toshiba satellite l15 Batteryhttp://www.batteryfast.com.au/toshiba/satellite-m30.htm Toshiba satellite m30 Batteryhttp://www.batteryfast.com.au/toshiba/satellite-m45.htm Toshiba satellite m45 Batteryhttp://www.batteryfast.com.au/toshiba/satellite-m55.htm Toshiba satellite m55 Batteryhttp://www.batteryfast.com.au/toshiba/satellite-p205.htm Toshiba satellite p205 Batteryhttp://www.batteryfast.com.au/hp/nc8000.htm Hp nc8000 Batteryhttp://www.batteryfast.com.au/hp/r3000.htm Hp r3000 Batteryhttp://www.batteryfast.com.au/hp/v6000.htm Hp v6000 Batteryhttp://www.batteryfast.com.au/hp/pavilion-dv9000.htm Hp pavilion dv9000 Batteryhttp://www.batteryfast.com.au/hp/pavilion-dv9500.htm Hp pavilion dv9500 Batteryhttp://www.batteryfast.com.au/hp/pavilion-dv9600.htm Hp pavilion dv9600 Batteryhttp://www.batteryfast.com.au/hp/pavilion-dv9700.htm Hp pavilion dv9700 Batteryhttp://www.batteryfast.com.au/hp/pavilion-tx1000.htm Hp pavilion tx1000 Batteryhttp://www.batteryfast.com.au/hp/pavilion-tx1100.htm Hp pavilion tx1100 Batteryhttp://www.batteryfast.com.au/ibm/thinkpad-r50.htm Ibm thinkpad r50 Batteryhttp://www.batteryfast.com.au/ibm/thinkpad-r51.htm Ibm thinkpad r51 Batteryhttp://www.batteryfast.com.au/ibm/thinkpad-x40.htm Ibm thinkpad x40 Batteryhttp://www.batteryfast.com.au/ibm/thinkpad-x41.htm Ibm thinkpad x41 Batteryhttp://www.batteryfast.com.au/ibm/thinkpad-z60m.htm Ibm thinkpad z60m Batteryhttp://www.batteryfast.com.au/ibm/thinkpad-z61e.htm Ibm thinkpad z61e Batteryhttp://www.batteryfast.com.au/ibm/thinkpad-z61t.htm Ibm thinkpad z61t Batteryhttp://www.batteryfast.com.au/laptop-ac-adapter/acer/1600.htm Acer 1600 Adapterhttp://www.batteryfast.com.au/laptop-ac-adapter/acer/1680.htm Acer 1680 Adapterhttp://www.batteryfast.com.au/laptop-ac-adapter/acer/5100.htm Acer 5100 Adapterhttp://www.batteryfast.com.au/laptop-ac-adapter/acer/5720.htm Acer 5720 Adapterhttp://www.batteryfast.com.au/laptop-ac-adapter/acer/as07b41.htm Acer as07b41 Adapterhttp://www.batteryfast.com.au/laptop-ac-adapter/acer/aspire-1400.htm Acer aspire 1400 Adapter

  3. Unknown says:

    http://www.batteryfast.com.au/ibm/thinkpad-r51.htm Ibm thinkpad r51 battery http://www.batteryfast.com.au/ibm/thinkpad-t20.htm Ibm thinkpad t20 battery http://www.batteryfast.com.au/ibm/thinkpad-t21.htm Ibm thinkpad t21 battery http://www.batteryfast.com.au/ibm/thinkpad-t22.htm Ibm thinkpad t22 battery http://www.batteryfast.com.au/ibm/thinkpad-t23.htm Ibm thinkpad t23 battery http://www.batteryfast.com.au/ibm/thinkpad-t42.htm Ibm thinkpad t42 battery http://www.batteryfast.com.au/ibm/thinkpad-t43.htm Ibm thinkpad t43 battery http://www.batteryfast.com.au/ibm/thinkpad-x20.htm Ibm thinkpad x20 battery http://www.batteryfast.com.au/ibm/thinkpad-x200.htm Ibm thinkpad x200 battery http://www.batteryfast.com.au/ibm/thinkpad-x21.htm Ibm thinkpad x21 battery http://www.batteryfast.com.au/ibm/thinkpad-x22.htm Ibm thinkpad x22 battery http://www.batteryfast.com.au/ibm/thinkpad-x23.htm Ibm thinkpad x23 battery http://www.batteryfast.com.au/ibm/thinkpad-X40.htm Ibm thinkpad X40 battery http://www.batteryfast.com.au/ibm/thinkpad-x41.htm Ibm thinkpad x41 battery http://www.batteryfast.com.au/ibm/thinkpad-x60.htm Ibm thinkpad x60 battery http://www.batteryfast.com.au/ibm/thinkpad-x60s.htm Ibm thinkpad x60s battery http://www.batteryfast.com.au/ibm/thinkpad-z60t.htm Ibm thinkpad z60t battery http://www.batteryfast.com.au/ibm/thinkpad-z61t.htm Ibm thinkpad z61t battery http://www.batteryfast.com.au/msi/bty-s11.htm Msi bty-s11 battery http://www.batteryfast.com.au/msi/bty-s12.htm Msi bty-s12 battery http://www.batteryfast.com.au/msi/wind-u100.htm Msi wind u100 battery http://www.batteryfast.com.au/msi/wind-u90.htm Msi wind u90 battery http://www.batteryfast.com.au/sony/pcga-bp2r.htm Sony pcga-bp2r battery http://www.batteryfast.com.au/sony/pcga-bpz51.htm Sony pcga-bpz51 battery http://www.batteryfast.com.au/sony/pcga-bpz51a.htm Sony pcga-bpz51a battery http://www.batteryfast.com.au/sony/pcga-bpz52.htm Sony pcga-bpz52 battery http://www.batteryfast.com.au/sony/vgp-bpl5a.htm Sony vgp-bpl5a battery http://www.batteryfast.com.au/sony/vgp-bps5.htm Sony vgp-bps5 battery http://www.batteryfast.com.au/sony/vgp-bps5a.htm Sony vgp-bps5a battery http://www.batteryfast.com.au/toshiba/pa3123u-1brs.htm Toshiba pa3123u-1brs battery http://www.batteryfast.com.au/toshiba/pa3178u-1bas.htm Toshiba pa3178u-1bas battery http://www.batteryfast.com.au/toshiba/pa3178u-1brs.htm Toshiba pa3178u-1brs battery http://www.batteryfast.com.au/toshiba/pa3211u-1bas.htm Toshiba pa3211u-1bas battery http://www.batteryfast.com.au/toshiba/pa3211u-1brs.htm Toshiba pa3211u-1brs battery http://www.batteryfast.com.au/toshiba/pa3479u-1brs.htm Toshiba pa3479u-1brs battery http://www.batteryfast.com.au/toshiba/pa3480u-1brs.htm Toshiba pa3480u-1brs battery http://www.batteryfast.com.au/toshiba/pa3591u-1bas.htm Toshiba pa3591u-1bas battery http://www.batteryfast.com.au/toshiba/pa3634u-1bas.htm Toshiba pa3634u-1bas battery http://www.batteryfast.com.au/toshiba/pa3635u-1bam.htm Toshiba pa3635u-1bam battery http://www.batteryfast.com.au/toshiba/pa3635u-1brm.htm Toshiba pa3635u-1brm battery http://www.batteryfast.com.au/toshiba/pa3638u-1bap.htm Toshiba pa3638u-1bap battery http://www.batteryfast.com.au/toshiba/pabas117.htm Toshiba pabas117 battery http://www.batteryfast.com.au/toshiba/pabas118.htm Toshiba pabas118 battery http://www.batteryfast.com.au/laptop-ac-adapter/hp/510.htm hp 510 adapterhttp://www.batteryfast.com.au/laptop-ac-adapter/hp/530.htm hp 530 adapter

  4. Unknown says:

    http://www.batteryfast.com.au/toshiba/pa3356u-3brs.htm Toshiba pa3356u-3brs Battery http://www.batteryfast.com.au/dell/xps-m1530.htm Dell xps m1530 Battery http://www.batteryfast.com.au/dell/xps-m1730.htm Dell xps m1730 Battery http://www.batteryfast.com.au/apple/a1185.htm Apple a1185 Battery http://www.batteryfast.com.au/dell/d620.htm Dell d620 Battery http://www.batteryfast.com.au/dell/d630.htm Dell d630 Battery http://www.batteryfast.com.au/dell/d820.htm Dell d820 Battery http://www.batteryfast.com.au/dell/d830.htm Dell d830 Battery http://www.batteryfast.com.au/dell/latitude-d820.htm Dell latitude d820 Battery http://www.batteryfast.com.au/dell/inspiron-6400.htm Dell inspiron 6400 Battery http://www.batteryfast.com.au/dell/inspiron-1520.htm Dell inspiron 1520 Battery http://www.batteryfast.com.au/dell/inspiron-1720.htm Dell inspiron 1720 Battery http://www.batteryfast.com.au/dell/vostro-1500.htm Dell vostro 1500 Battery http://www.batteryfast.com.au/dell/vostro-1700.htm Dell vostro 1700 Battery http://www.batteryfast.com.au/dell/latitude-d830.htm Dell latitude d830 Battery http://www.batteryfast.com.au/sony/vgp-bpl2c.htm Sony vgp-bpl2c Battery http://www.batteryfast.com.au/sony/vgp-bpl2.htm Sony vgp-bpl2 Battery http://www.batteryfast.com.au/laptop-ac-adapter/dell/dell-19.5V-3.34A-65w-7.4mm-5.0mm-with-pin-pa-12.php Dell E1505 D620 1520 1525 19.5V 3.34A 65W 7.4MM*5.0MM WITH PIN PA-12 Adapter http://www.batteryfast.com.au/laptop-ac-adapter/dell/dell-19.5V-4.62A-90w-7.4mm-5.0mm-with-pin-pa-10.php Dell 1150 9300 D810 19.5V 4.62A 90W 7.4MM*5.0MM WITH PIN PA-10 Adapter http://www.batteryfast.com.au/laptop-ac-adapter/dell/dell-19.5V-6.7A-130w-7.4mm-5.0mm-with-pin-pa-13.php Dell XPS M170 5150 19.5V 6.7A 130W 7.4MM*5.0MM WITH PIN PA-13 Adapter http://www.batteryfast.com.au/laptop-ac-adapter/acer/acer-19V-3.42A-65w-5.5mm-2.5mm-big-head.php Acer 1600 1680 19V 3.42A 65W 5.5MM*2.5MM Adapter http://www.batteryfast.com.au/laptop-ac-adapter/acer/acer-19V-3.42A-65w-5.5mm-1.5mm-small-head.php Acer 1600 1680 19V 3.42A 65W 5.5MM*1.7MM Adapter http://www.batteryfast.com.au/laptop-ac-adapter/asus/asus-19v-3.42A-65w-5.5mm-2.5mm.php Asus A2 A3 19V 3.42A 65W 5.5MM*2.5MM Adapter http://www.batteryfast.com.au/laptop-ac-adapter/dell/dell-19V-3.16A-60w-5.5mm-2.5mm.php Dell B130 1200 1300 PA-1600-06D2 19V 3.16A 60W 5.5MM*2.5MM Adapter http://www.batteryfast.com.au/laptop-ac-adapter/delta/delta-19V-3.42A-65w-5.5mm-2.5mm.php Delta 1680 3200 19V 3.42A 65W 5.5MM*2.5MM Adapter http://www.batteryfast.com.au/laptop-ac-adapter/delta/delta-19V-4.74A-90w-5.5mm-2.5mm.php Delta A6 F5 19V 4.74A 90W 5.5MM*2.5MM Adapter http://www.batteryfast.com.au/laptop-ac-adapter/fujitsu/fujitsu-19V-3.16A-60w-5.5mm-2.5mm.php Fujitsu A4190 S7000 19V 3.16A 60W 5.5MM*2.5MM Adapter http://www.batteryfast.com.au/laptop-ac-adapter/hp/hp-19V-4.74A-90w-4.8mm-1.7mm.php Hp NC6000 NC8230 19V 4.74A 90W 4.8MM*1.7MM Adapter http://www.batteryfast.com.au/laptop-ac-adapter/ibm/ibm-16V-3.5A-56w-5.5mm-2.5mm.php Ibm T40 X30 R30 16V 3.5A 56W 5.5MM*2.5MM Adapter http://www.batteryfast.com.au/laptop-ac-adapter/ibm/ibm-20V-3.25A-65w-7.9mm-5.5mm-DC-with-pin-inside.php Ibm Z60M X60 2530 20V 3.25A 65W 7.9MM*5.5MM DC WITH PIN INSIDE Adapter http://www.batteryfast.com.au/laptop-ac-adapter/liteon/liteon-19V-3.42A-65w-5.5mm-2.5mm-white.php Liteon M320 M680 M360 19V 3.42A 65W 5.5MM*2.5MM Adapter

  5. Unknown says:

    http://www.batterylaptoppower.com/dell/inspiron-6400.htm Dell inspiron 6400 Battery http://www.batterylaptoppower.com/dell/vostro-1000.htm Dell vostro 1000 Battery http://www.batterylaptoppower.com/dell/e1505.htm Dell e1505 Battery http://www.batterylaptoppower.com/dell/1501.htm Dell 1501 Battery http://www.batterylaptoppower.com/dell/kd476.htm Dell kd476 Battery http://www.batterylaptoppower.com/dell/gd761.htm Dell gd761 Battery http://www.batterylaptoppower.com/hp/530.htm Hp 530 Battery http://www.batterylaptoppower.com/dell/d620.htm Dell d620 Battery http://www.batterylaptoppower.com/dell/d630.htm Dell d630 Battery http://www.batterylaptoppower.com/dell/d820.htm Dell d820 Battery http://www.batterylaptoppower.com/dell/d830.htm Dell d830 Battery http://www.batterylaptoppower.com/dell/latitude-d820.htm Dell latitude d820 Battery http://www.batterylaptoppower.com/sony/vgp-bps2b.htm Sony vgp-bps2b Battery http://www.batterylaptoppower.com/ibm/thinkpad-t30.htm Ibm thinkpad t30 Battery http://www.batterylaptoppower.com/dell/latitude-d830.htm Dell latitude d830 Battery http://www.batterylaptoppower.com/dell/precision-m65.htm Dell precision m65 Battery http://www.batterylaptoppower.com/dell/inspiron-6000.htm Dell inspiron 6000 Battery http://www.batterylaptoppower.com/dell/inspiron-9300.htm Dell inspiron 9300 Battery http://www.batterylaptoppower.com/dell/inspiron-9400.htm Dell inspiron 9400 Battery http://www.batterylaptoppower.com/dell/inspiron-e1705.htm Dell inspiron e1705 Battery http://www.batterylaptoppower.com/dell/d5318.htm Dell d5318 Battery http://www.batterylaptoppower.com/dell/inspiron-1520.htm Dell inspiron 1520 Battery http://www.batterylaptoppower.com/dell/inspiron-1720.htm Dell inspiron 1720 Battery http://www.batterylaptoppower.com/dell/vostro-1500.htm Dell vostro 1500 Battery http://www.batterylaptoppower.com/dell/vostro-1700.htm Dell vostro 1700 Battery http://www.batterylaptoppower.com/dell/original-inspiron-1525.htm Dell original inspiron 1525 Battery http://www.batterylaptoppower.com/dell/xps-m1210.htm Dell xps m1210 Battery http://www.batterylaptoppower.com/dell/inspiron-b130.htm Dell inspiron b130 Battery http://www.batterylaptoppower.com/dell/inspiron-1300.htm Dell inspiron 1300 Battery http://www.batterylaptoppower.com/hp/m2000.htm Hp m2000 Battery http://www.batterylaptoppower.com/hp/nc2400.htm Hp nc2400 Battery http://www.batterylaptoppower.com/mitac/bp-8×99.htm Mitac bp-8×99 Battery http://www.batterylaptoppower.com/sony/vgp-bps2c.htm Sony vgp-bps2c Battery http://www.batterylaptoppower.com/sony/vgp-bps2a.htm Sony vgp-bps2a Battery http://www.batterylaptoppower.com/sony/vgp-bps2b.htm Sony vgp-bps2b Battery http://www.batterylaptoppower.com/sony/vgp-bps2.htm Sony vgp-bps2 Battery http://www.batterylaptoppower.com/ibm/thinkpad-t30.htm Ibm thinkpad t30 Battery http://www.batterylaptoppower.com/hp/nc6000.htm Hp nc6000 Battery http://www.batterylaptoppower.com/hp/nx5000.htm Hp nx5000 Battery http://www.batterylaptoppower.com/hp/nc8000.htm Hp nc8000 Battery http://www.batterylaptoppower.com/mitac/bp-8050.htm Mitac bp-8050 Battery http://www.batterylaptoppower.com/hp/2510p.htm Hp 2510p Battery http://www.batterylaptoppower.com/gateway/m360.htm Gateway m360 Battery

  6. says:

    http://www.batteryfast.com/asus/f3.htm Asus f3 Battery http://www.batteryfast.com/toshiba/pa3594u-1brs.htm Toshiba pa3594u-1brs Battery http://www.batteryfast.com/toshiba/pa3593u-1bas.htm Toshiba pa3593u-1bas Battery http://www.batteryfast.com/toshiba/pabas111.htm Toshiba pabas111 Battery http://www.batteryfast.com/dell/xps-m1530.htm Dell xps m1530 Battery http://www.batteryfast.com/hp/tx2000.htm Hp tx2000 Battery http://www.batteryfast.com/hp/pavilion-tx1000.htm Hp pavilion tx1000 Battery http://www.batteryfast.com/dell/xps-m1730.htm Dell xps m1730 Battery http://www.batteryfast.com/hp/pavilion-dv6.htm Hp pavilion dv6 Battery http://www.batteryfast.com/toshiba/pa3395u-1brs.htm Toshiba pa3395u-1brs Battery http://www.batteryfast.com/toshiba/pa3421u-1brs.htm Toshiba pa3421u-1brs Battery http://www.batteryfast.com/toshiba/pa3451u-1brs.htm Toshiba pa3451u-1brs Battery http://www.batteryfast.com/toshiba/pa3399u-1brs.htm Toshiba pa3399u-1brs Battery http://www.batteryfast.com/toshiba/pa3399u-2bas.htm Toshiba pa3399u-2bas Battery http://www.batteryfast.com/toshiba/satellite-a100.htm Toshiba satellite a100 Battery http://www.batteryfast.com/toshiba/satellite-m40.htm Toshiba satellite m40 Battery http://www.batteryfast.com/toshiba/satellite-m45.htm Toshiba satellite m45 Battery http://www.batteryfast.com/toshiba/satellite-m55.htm Toshiba satellite m55 Battery http://www.batteryfast.com/toshiba/pa3356u.htm Toshiba pa3356u Battery http://www.batteryfast.com/toshiba/pa3356u-1bas.htm Toshiba pa3356u-1bas Battery http://www.batteryfast.com/toshiba/pa3356u-1brs.htm Toshiba pa3356u-1brs Battery http://www.batteryfast.com/toshiba/pa3356u-2brs.htm Toshiba pa3356u-2brs Battery http://www.batteryfast.com/toshiba/pa3456u-1brs.htm Toshiba pa3456u-1brs Battery http://www.batteryfast.com/toshiba/portege-m500.htm Toshiba portege m500 Battery http://www.batteryfast.com/toshiba/pa3451u.htm Toshiba pa3451u Battery http://www.batteryfast.com/toshiba/pabas067.htm Toshiba pabas067 Battery http://www.batteryfast.com/toshiba/pa3465u-1brs.htm Toshiba pa3465u-1brs Battery http://www.batteryfast.com/toshiba/pa3534u-1brs.htm Toshiba pa3534u-1brs Battery http://www.batteryfast.com/toshiba/pa3533u-1bas.htm Toshiba pa3533u-1bas Battery http://www.batteryfast.com/toshiba/satellite-a205.htm Toshiba satellite a205 Battery http://www.batteryfast.com/toshiba/pa3534u-1bas.htm Toshiba pa3534u-1bas Battery http://www.batteryfast.com/uniwill/255-3s4400-g1l1.htm Uniwill 255-3s4400-g1l1 Battery http://www.batteryfast.com/uniwill/un255.htm Uniwill un255 Battery

  7. Unknown says:

    http://www.batteryfast.com/asus/f3.htm Asus f3 Battery http://www.batteryfast.com/toshiba/pa3594u-1brs.htm Toshiba pa3594u-1brs Battery http://www.batteryfast.com/toshiba/pa3593u-1bas.htm Toshiba pa3593u-1bas Battery http://www.batteryfast.com/toshiba/pabas111.htm Toshiba pabas111 Battery http://www.batteryfast.com/dell/xps-m1530.htm Dell xps m1530 Battery http://www.batteryfast.com/hp/tx2000.htm Hp tx2000 Battery http://www.batteryfast.com/hp/pavilion-tx1000.htm Hp pavilion tx1000 Battery http://www.batteryfast.com/dell/xps-m1730.htm Dell xps m1730 Battery http://www.batteryfast.com/hp/pavilion-dv6.htm Hp pavilion dv6 Battery http://www.batteryfast.com/toshiba/pa3395u-1brs.htm Toshiba pa3395u-1brs Battery http://www.batteryfast.com/toshiba/pa3421u-1brs.htm Toshiba pa3421u-1brs Battery http://www.batteryfast.com/toshiba/pa3451u-1brs.htm Toshiba pa3451u-1brs Battery http://www.batteryfast.com/toshiba/pa3399u-1brs.htm Toshiba pa3399u-1brs Battery http://www.batteryfast.com/toshiba/pa3399u-2bas.htm Toshiba pa3399u-2bas Battery http://www.batteryfast.com/toshiba/satellite-a100.htm Toshiba satellite a100 Battery http://www.batteryfast.com/toshiba/satellite-m40.htm Toshiba satellite m40 Battery http://www.batteryfast.com/toshiba/satellite-m45.htm Toshiba satellite m45 Battery http://www.batteryfast.com/toshiba/satellite-m55.htm Toshiba satellite m55 Battery http://www.batteryfast.com/toshiba/pa3356u.htm Toshiba pa3356u Battery http://www.batteryfast.com/toshiba/pa3356u-1bas.htm Toshiba pa3356u-1bas Battery http://www.batteryfast.com/toshiba/pa3356u-1brs.htm Toshiba pa3356u-1brs Battery http://www.batteryfast.com/toshiba/pa3356u-2brs.htm Toshiba pa3356u-2brs Battery http://www.batteryfast.com/toshiba/pa3456u-1brs.htm Toshiba pa3456u-1brs Battery http://www.batteryfast.com/toshiba/portege-m500.htm Toshiba portege m500 Battery http://www.batteryfast.com/toshiba/pa3451u.htm Toshiba pa3451u Battery http://www.batteryfast.com/toshiba/pabas067.htm Toshiba pabas067 Battery http://www.batteryfast.com/toshiba/pa3465u-1brs.htm Toshiba pa3465u-1brs Battery http://www.batteryfast.com/toshiba/pa3534u-1brs.htm Toshiba pa3534u-1brs Battery http://www.batteryfast.com/toshiba/pa3533u-1bas.htm Toshiba pa3533u-1bas Battery http://www.batteryfast.com/toshiba/satellite-a205.htm Toshiba satellite a205 Battery http://www.batteryfast.com/toshiba/pa3534u-1bas.htm Toshiba pa3534u-1bas Battery http://www.batteryfast.com/uniwill/255-3s4400-g1l1.htm Uniwill 255-3s4400-g1l1 Battery http://www.batteryfast.com/uniwill/un255.htm Uniwill un255 Battery

  8. Unknown says:

    nice try, but is not what I was looking for. Thanks.http://www.musicaliquida.com

  9. Unknown says:

    ダッチワイフ

    まつげエクステ

    アダルトグッズ

    英語 勉強

    競馬予想

    フラワーアレンジ

    ブリザーブドフラワー

    バラ

    供花

    誕生花

    誕生日プレゼント 花

    北欧家具

    ローズオイル

    ブライダル エステ

    大人のおもちゃ通販

    結婚式

    結婚式準備

    結婚式の髪型

    ウェディングドレス

    av サンプル 動画

    アダルト
    ダウンロード

    熟女
    アダルト

    巨乳
    アダルト

    素人
    アダルト

    ニューハーフ
    アダルト

    FX ランキング

    FX 比較

    キャッシング 申込

    債務整理

  10. Unknown says:

    探偵 調査

    素行調査

    身辺調査

    妻浮気

    悩み相談

    探偵紹介

    探偵事務所

    行動調査

    追跡調査

    結婚式

    電話占い

    アダルト通販

    オナホール

    TENGA

    バイブ

    コスプレ

    大人のおもちゃ

    アダルトグッズ

    アダルトグッズ

    大人のおもちゃ

    アダルトグッズ

    エアコン工事

    ガーデンファニチャー

    システムキッチン

    洗面化粧台

    洗面台

    アロマオイル

    医学翻訳

    大人のおもちゃ

    アダルトショップ 

    エネマグラ

    オナホール 

    仮性包茎

    アナル

    電マ

  11. Unknown says:

    Sorry, I\’m taking my last comment back. This is a useless piece of code.
    It is full of bugs (example: allows historical values to be added and causes unhandled exception), and is limited to a future event no greater than Int32.MaxValue in milliseconds, otherwise (again) throws an unhandled exception.
    Nice try, yet very non proffessional. I recommend no one to use it.

  12. Unknown says:

    Thank you. I\’m using your Scheduler.
     
    One note: it does not support multiple events occuring at the same time. I would consider adding that functionality, since any application might require that.
     
    Zack

  13. Prasad says:

    Thx William for your time and effort. This is what exactly I am looking for.

  14. William says:

    Hi adsiz.
    Just use delegate syntax such as:
    new delegate(object obj)
    {
          //do something.
    }

  15. ibrahim says:

    I want schedule a task in my c# web application but I cant compile TestTaskScheduler classthe first line has the problem "TimerTask tt = TaskScheduler.Add(DateTime.Now, () =>  Debug.WriteLine("Task1 done."));"I cannot use lambda syntax (I think) in .NET 2.0Is there any alternative usage ?Thanks in advance

Comments are closed.