0

I am making a program that has a timer inside of it. I want the timer to be able to display milliseconds so I used the timer from the tool bar in VB and I fiddled around with the intervals but I cant get it to measure 1 millisecond. I have searched around a lot and I could not find anything useful accept one thing called System.Timers.Timer but I cant figure out how to use it. So could someone tell me what number of intervals = 1 millisecond and what System.Timers.Timer is and how to use it.
For help helping me: In my code the timer adds one to a variable called mili every time it ticks and then displays that in a text box. When mili = 1000 it adds one to a variable called seconds and when seconds hits 60 it does the same for minuets.

Private Sub Timer_Tick(sender As Object, e As EventArgs) Handles Timer.Tick
mili = mili + 1
If mili = 1000 Then
mili = 0
second = second + 1
lblsec.Text = second

Thanks in advance.

Ňɏssa Pøngjǣrdenlarp
  • 38,411
  • 12
  • 59
  • 178
Nathan
  • 41
  • 5
  • 1
    Possible duplicate of [Why are .NET timers limited to 15 ms resolution?](http://stackoverflow.com/questions/3744032/why-are-net-timers-limited-to-15-ms-resolution) – Nate Barbettini Jun 07 '16 at 19:31
  • 1
    Take a look at this answer for information on a high resolution timer if you need it [How do you test running time of VBA code?](http://stackoverflow.com/a/198702/4717755) – PeterT Jun 07 '16 at 19:35

0 Answers0