DelayMS

Timers

procedure DelayMS(mSecs : DWORD; Yield : Boolean);

Delays for a specified number of milliseconds.

If Yield is False, DelayMS does not yield to other applications and returns control only after mSecs milliseconds elapse. In this case the function result is always zero.

If Yield is True, DelayMS yields to other applications and to the owning application by periodically calling Application.HandleMessage.

Even with Yield set to True, DelayMS should not be used to delay for periods of time longer than a few seconds. For longer delays, you should set up an EventTimer or a timer trigger and continue the execution of your program until the timer expires.