View Single Post
  #1 (permalink)  
Old 08-16-2006, 09:51 AM
hoser2001's Avatar   
hoser2001 hoser2001 is offline
Programmer
 
Join Date: Jul 2006
Posts: 175
Credits: 0
Rep Power: 11
hoser2001 is on a distinguished road
Default Here is a Code Execution Timer

Code:
System.DateTime tm = System.DateTime.Now;
//Place this before the code you wish to test.

System.DateTime tma = System.DateTime.Now;
System.IO.StreamWriter sw = System.IO.File.AppendText("C:\\TimeTest.txt");
sw.WriteLine((((((tma.Hour * (24 * 60 * 1000)) + (tma.Minute * (60 * 1000))) + (tma.Second * 1000)) + tma.Millisecond) - ((((tm.Hour * (24 * 60 * 1000)) + (tm.Minute * (60 * 1000))) + (tm.Second * 1000)) + tm.Millisecond)));
sw.Flush();
//place this after your code
Reply With Quote

Sponsored Links