PC SOFT

WINDEVWEBDEV AND WINDEV MOBILE
ONLINE HELP

Home | Sign in | English UK
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
Waits for the end of execution of specified thread. A maximum time-out can be specified.
Reminder: A thread is a process run in parallel of current application (main thread). This allows you to run a task in background task for example (backup, ...).
Example
ThreadExecute("Thread1", threadNormal, ThreadProcedure)
...
ThreadWait("Thread1", 300)
Versions 25 and later
iPhone/iPadApple WatchUniversal Windows 10 AppWindows Mobile
// Build a thread
t is Thread(Proc, ("First parameter", 2))
// Trigger the execution of the thread
ThreadExecute(t)
...
ThreadWait(t, 300)
New in version 25
iPhone/iPadApple WatchUniversal Windows 10 AppWindows Mobile
// Build a thread
t is Thread(Proc, ("First parameter", 2))
// Trigger the execution of the thread
ThreadExecute(t)
...
ThreadWait(t, 300)
iPhone/iPadApple WatchUniversal Windows 10 AppWindows Mobile
// Build a thread
t is Thread(Proc, ("First parameter", 2))
// Trigger the execution of the thread
ThreadExecute(t)
...
ThreadWait(t, 300)
Syntax

Wait for the end of the thread execution (use thread name) Hide the details

<Result> = ThreadWait(<Thread name> [, <Maximum timeout>])
<Result>: Boolean
  • True if the thread was stopped or if the thread does not exist,
  • False if the thread is not stopped (the maximum duration is exceeded).
<Thread name>: Character string (with quotes)
Name of thread for which we must wait for the end of execution. This name is given when running the thread (ThreadExecute).
<Maximum timeout>: Optional integer, optional duration or optional constant
Maximum timeout in hundredths of a second.
  • If the thread is not stopped at the end of specified duration, <Result> is set to False.
  • If this parameter is not specified or if it corresponds to the Infinite constant, the wait is infinite.
This parameter can correspond to:
  • an integer corresponding to the number of hundredths of a second,
  • a Duration variable,
  • Versions 23 and later
    the direct indication of duration (1 s or 10 ms for example).
    New in version 23
    the direct indication of duration (1 s or 10 ms for example).
    the direct indication of duration (1 s or 10 ms for example).
Versions 25 and later
iPhone/iPadApple WatchUniversal Windows 10 AppWindows Mobile

Wait for the end of the thread execution (use of a Thread variable) Hide the details

<Result> = ThreadWait(<Thread to wait for> [, <Maximum timeout>])
<Result>: Boolean
  • True if the thread was stopped or if the thread does not exist,
  • False if the thread is not stopped (the maximum duration is exceeded).
<Thread to wait for>: Thread variable
Name of the Thread variable corresponding to the thread that must stop.
<Maximum timeout>: Optional integer, optional duration or optional constant
Maximum timeout in hundredths of a second.
  • If the thread is not stopped at the end of specified duration, <Result> is set to False.
  • If this parameter is not specified or if it corresponds to the Infinite constant, the wait is infinite.
This parameter can correspond to:
  • an integer corresponding to the number of hundredths of a second,
  • a Duration variable,
  • the direct indication of duration (1 s or 10 ms for example).
New in version 25
iPhone/iPadApple WatchUniversal Windows 10 AppWindows Mobile

Wait for the end of the thread execution (use of a Thread variable) Hide the details

<Result> = ThreadWait(<Thread to wait for> [, <Maximum timeout>])
<Result>: Boolean
  • True if the thread was stopped or if the thread does not exist,
  • False if the thread is not stopped (the maximum duration is exceeded).
<Thread to wait for>: Thread variable
Name of the Thread variable corresponding to the thread that must stop.
<Maximum timeout>: Optional integer, optional duration or optional constant
Maximum timeout in hundredths of a second.
  • If the thread is not stopped at the end of specified duration, <Result> is set to False.
  • If this parameter is not specified or if it corresponds to the Infinite constant, the wait is infinite.
This parameter can correspond to:
  • an integer corresponding to the number of hundredths of a second,
  • a Duration variable,
  • the direct indication of duration (1 s or 10 ms for example).
iPhone/iPadApple WatchUniversal Windows 10 AppWindows Mobile

Wait for the end of the thread execution (use of a Thread variable) Hide the details

<Result> = ThreadWait(<Thread to wait for> [, <Maximum timeout>])
<Result>: Boolean
  • True if the thread was stopped or if the thread does not exist,
  • False if the thread is not stopped (the maximum duration is exceeded).
<Thread to wait for>: Thread variable
Name of the Thread variable corresponding to the thread that must stop.
<Maximum timeout>: Optional integer, optional duration or optional constant
Maximum timeout in hundredths of a second.
  • If the thread is not stopped at the end of specified duration, <Result> is set to False.
  • If this parameter is not specified or if it corresponds to the Infinite constant, the wait is infinite.
This parameter can correspond to:
  • an integer corresponding to the number of hundredths of a second,
  • a Duration variable,
  • the direct indication of duration (1 s or 10 ms for example).
Business / GUI classification : Neutral code
Component : wd250vm.dll
Minimum version required
  • Version 9
This page is also available for…
Comments
Click [Add] to post a comment