Starting a timer¶
StartTimer() |
Start a timer |
SYNTAX
StartTimer(event_function[, millisecond_interval]))
Create a new timer. Multiple timers can be created, and can run concurrently.
event_function |
The event function of the timer to be started. The function name was assigned by CreateTimer() when the timer was created. |
millisecond_interval |
A positive integer, defining the interval in milliseconds between calls to the timer’s event function. Under UNIX, the millisecond_interval is rounded up to the next second, because most UNIX system clocks run with granularity of one second. Under Windows, the millisecond_interval is used. This argument is optional. If no interval is specified, the default assigned to the timer by the CreateTimer() function is used. |
The function returns 0 if successful, or a negative value if it fails.
EXAMPLE
CreateTimer(evTimer, 1000, TIMER_START}
StartTimer(evTimer, 1500)
...
StopTimer(evTimer}
RELATED TOPICS |