i'm possible
using System.Diagnostics;Stopwatch sw = new Stopwatch();sw.Reset();sw = Stopwatch.StartNew();//要測時間的程式碼放這裡sw.Stop();TimeSpan e1 = sw.Elapsed;long ms = sw.ElapsedMilliseconds;MessageBox.Show(e1 + "秒 " + ms + "毫秒");
沒有留言:
張貼留言