Sleep

Metreos.ApplicationControl.Sleep

Summary

Sleep causes the script to pause execution for the specified number of milliseconds.

Usage

The Sleep action can be used whenever a short pause is needed during the execution of a function in a script instance.

Remarks

Sleep causes the script to pause while executing a function, which means other events rising up to the application for processing are being queued. Using Sleep for a long amount of time runs counter to the best practice of spending as little amount of time in a function, due to the fact only one event can be processed at a time. If a long delay is needed, then consider instead using AddTriggerTimer or AddNonTriggerTimer.

Sleep does not use a thread in the Application Runtime threadpool while sleeping.

Action Parameters
Parameter Name.NET TypeDefaultDescription
SleepTime *System.Int32The amount of time to sleep (in milliseconds).

No Result Data

Branch Conditions 

success

No description.

failure

No description.