Hi I was wondering how can you make an application pause for less than a second without using a timer control event?
Thankyou
Printable View
Hi I was wondering how can you make an application pause for less than a second without using a timer control event?
Thankyou
use the sleep() API call. It lets you specify the number of milliseconds to sleep for, and also tells Windows that something else can have the processor time :)
Note that this will prevent the app from responding to user events.Code:Declare Sub Sleep Lib "kernel32" (ByVal dwMilliseconds As Long)
Sleep numberOfMillisecondsToSleepFor
Hope this helps :)
Thanks this helps heaps :)
Keep in mind that the shortest delay you can have is 10ms. =)
Then I think timer is better.
:p Kinjal :p
Timer is the same way.
didn't you hear about the new Microsoft Math?
1 = 10 Maybe
5 = 10 Maybe
7 = 10 Maybe
11 = 20 Maybe 15
You can't trust these routines at short frequencies.
I have done multiple test on this, it's a nightmare for fast COM port timing.
Good Luck :)