Waits until either specified object is in the signaled state, or until the time-out interval elapses.
DWORD WaitForMultipleObjects( DWORD nCount, CONST HANDLE * lpHandles, BOOLEAN bWaitAll, DWORD dwMilliseconds ); DWORD RtWaitForMultipleObjects( DWORD nCount, CONST HANDLE * lpHandles, BOOLEAN bWaitAll, DWORD dwMilliseconds );
nCount
lpHandles
. The maximum number of object handles is MAXIMUM_WAIT_OBJECTS which, in INtime, is 16.
lpHandles
bWaitAll
dwMilliseconds
bWaitAll
parameter are not met. If dwMilliseconds
is zero, the function tests the states of specified objects and returns immediately. If dwMilliseconds
is INFINITE, the function's time-out interval never elapses. When one object is deleted while the thread waits, the thread wakes and ERROR_INVALID_HANDLE is set.
These functions cannot be called from a pure INtime thread.
WaitForMultipleObjects can specify handles of any of the following object types in the lpHandles array:
WAIT_OBJECT_0 to (WAIT_OBJECT_0 + nCount - 1) |
Success. The return value minus WAIT_OBJECT_0 indicates the lpHandles array index of the object that satisfied the wait. If more than one object became signaled during the call, this is the array index of the first signaled object. |
WAIT_ABANDONED_0 to (WAIT_ABANDONED_0 + nCount - 1) |
Success. The return value minus WAIT_ABANDONED_0 indicates the lpHandles array index of the object that was deleted while waiting. |
WAIT_TIMEOUT | Success. The time-out interval elapsed and the condition specified by the fWaitAll parameter is not satisfied. |
WAIT_FAILED | Failure. For extended error information, see GetLastError. |
Versions | Defined in | Include | Link to |
---|---|---|---|
INtime 3.0 | intime/rt/include/iwin32.h intime/rt/include/winbase.h |
iwin32.h windows.h |
iwin32.lib |
Notes