Pauses for a given interval in milliseconds.

Namespace: ASCOM.Utilities.Interfaces
Assembly: ASCOM.Utilities (in ASCOM.Utilities.dll) Version: 6.0.0.0 (6.1.1.2619)

Syntax

C#
void WaitForMilliseconds(
	int Milliseconds
)
Visual Basic
Sub WaitForMilliseconds ( _
	Milliseconds As Integer _
)
Visual C++
void WaitForMilliseconds(
	int Milliseconds
)

Parameters

Milliseconds
Type: System..::..Int32
The number of milliseconds to wait

Remarks

Repeatedly puts the calling Win32 process to sleep, totally freezing it, for 10 milliseconds, then pumps events so the script or program calling it will receive its normal flow of events, until the pause interval elapses. If the pause interval is 20 milliseconds or less, the sleep interval is reduced to 0, causing the calling Win32 process to give up control to the kernel scheduler and then immediately become eligible for scheduling.

See Also