int = WaitForSingleObject(hHandle, milliseconds )
Returns when an event is signalled
Return ValueIf the function succeeds, the return value indicates the event that caused the function to return. This value can be one of the following.
|WAIT_ABANDONED||The specified object is a mutex object that was not released by the thread that owned the mutex object before the owning thread terminated. Ownership of the mutex object is granted to the calling thread, and the mutex is set to nonsignaled.|
|WAIT_OBJECT_0||The state of the specified object is signaled.|
|WAIT_TIMEOUT||The time-out interval elapsed, and the object's state is nonsignaled.|