ptid (PTID) - in/out

      Address of the thread identification.

      Input

        The address of the ThreadID of the thread of interest. If ptid is 0, the current thread waits until the next thread in the process has ended. If ptid is nonzero, the current thread waits until the indicated thread has ended.
      Output
        The ThreadID of the ended thread is returned in this field.

      option (ULONG) - input

        An indicator that specifies whether to return if no thread has ended.

        The values of this field are shown in the following list:

      • DCWW_WAIT The current thread waits until a thread ends. If a thread has already ended, the call returns immediately with the ptid.

      • DCWW_NOWAIT
        The current thread does not wait if no threads have ended.

      ulrc (APIRET) - returns

        Return Code.

        DosWaitThread returns one of the following values:

      • NO_ERROR 95
          ERROR_INTERRUPT
        294
          ERROR_THREAD_NOT_TERMINATED
        309
          ERROR_INVALID_THREADID
        For a full list of error codes, see Errors.


      [Back] [Next]