Question calculate execution time

mmy

Member
Joined
Oct 5, 2007
Messages
24
Programming Experience
1-3
Hi,

is there a way to calculate the execution time between 2 lines of code in vb.net? I know debugging software exists to do this, but I couldn't find any freeware till now.

There must be a tool in visual studio / or in the debug mode to do this?
Or do I have to use the datetime function and calculate the time difference between endtime and starttime?

Thanks
 
In the help file take a look at the stopwatch class, it has a nice example. I use this and log to a file different execution times.
 
thanks for the reply! I looked at the class for a seconds, and seems pretty easy. I used it in some test code and seems to work good. I'll implement it later.

Thanks
 
Back
Top