PC SOFT

ONLINE HELP
FOR WINDEV, WEBDEV AND WINDEV MOBILE

Home | Sign in | English US
  • Stop
  • Tips/Notes
WINDEV
WindowsLinuxUniversal Windows 10 AppJavaReports and QueriesUser code (UMC)
WEBDEV
WindowsLinuxPHPWEBDEV - Browser code
WINDEV Mobile
AndroidAndroid Widget iPhone/iPadApple WatchUniversal Windows 10 AppWindows Mobile
Others
Stored procedures
Temporarily stops the program execution.
Example
// Wait during 1s
Wait(100, waitRedraw)
Syntax
Wait(<Wait> [, <Type>])
<Wait>: Integer
Time-out in hundredths of a second.
  • The function has no effect if a negative value is used.
  • If this parameter is set to 0, the function processes all the pending events and takes control immediately.
Regardless of the parameter value, the optional processes of controls are always run. Note: This parameter can correspond to:
  • an integer corresponding to the number of hundredths of a second,
  • a Duration variable,
  • Versions 23 and later
    the indication of duration in clear ('1s' or '10cs' for example).
    New in version 23
    the indication of duration in clear ('1s' or '10cs' for example).
    the indication of duration in clear ('1s' or '10cs' for example).
<Type>: Optional constant
Type of event that can be run during the wait:
waitRedraw
(by default)
The windows and the controls can be redrawn.
waitNothingNo event can be run.
waitMouseAndKeyboardThe windows and the controls can be redrawn.
The timers can be run.
The mouse actions (click on controls for example) or the keyboard events can be run.
Note: This constant is equivalent to Multitask used with a negative value.
waitTimerThe windows and the controls can be redrawn.
The timers can be run.
Note: This constant is equivalent to Multitask used with a positive value.
Remarks

Stop

The stop only affects the current thread. The other threads continue to run normally.

Tips/Notes

  • We recommend that you use ThreadPause or ServiceWait instead of Multitask or Wait when several threads are used (including for the main application thread) if the user actions do not have to be processed by the wait.
  • Wait prevents the process from ending as long as the requested temporization is not completed. We advise you not to use a long temporization but to perform several short temporizations in a loop. For example, you can replace:
    Wait(10000, waitMouseAndKeyboard)

    by:
    LOOP (100)
    Wait(100, waitMouseAndKeyboard)
    END
  • In a Service application, Wait must be replaced by ServiceWait.
Components
WINDEVReports and Queries wd230obj.dll
Windows Mobile wp230obj.dll
Minimum required version
  • Version 10
This page is also available for…
Comments
Click [Add] to post a comment