using System.Timers;

public static void Main (string[] args){

    System.Timers.Timer t = new System.Timers.Timer(1000);
    t.Elapsed += new ElapsedEventHandler(run);
    t.Enabled = true;

}

 

public static void run(object source,System.Timers.ElapsedEventArgs e){

    Console.WriteLine("OK");

}

 

 

 

 

arrow
arrow
    全站熱搜

    黃彥霖 發表在 痞客邦 留言(0) 人氣()