M3BNe‖WaitUntil Statement

Contents
9TiAi‖

# vrA77‖WaitUntil Statement

2Cmcm‖Interrupts the program execution until the time specified.

### FVEx2‖Syntax:

gYbAt‖WaitUntil Time

### WADQ4‖Parameters:

ExzB7‖ Time: A Date and Time expression that contains the date and time to wait before the program is executed.

### SEjHR‖Error codes:

5 Invalid procedure call

### EFSA4‖Example:

            VMUCS‖REM Wait until 6:00 PM then call MyMacro.
            XYXGw‖REM If after 6:00 PM, exit.
            Sub ExampleWaitUntil
            Dim vTimeschedule As Double
                vTimeSchedule = Date() + TimeValue("18:00:00")
                If vTimeSchedule < Now() Then Exit Sub
                WaitUntil vTimeSchedule
                Call MyMacro
            End Sub

Related Topics

oyAyY‖Wait statement

Please support us!