ThreadID Property

Applies to:  Thread object
See also:  

Returns the Windows assigned ThreadID for the thread.

Syntax:

object.ThreadID

The ThreadID syntax has these parts:

Part Description
object The name of a Thread object.

Remarks:

If the Thread object is the return value of GetAllThreads, then the value returned by the ThreadID property will be 0.

If the Thread object is the Thread property of a Window object, or the return value of ThisThread or WrapThread, then the value returned by the ThreadID property will be the Windows assigned ThreadID for the thread.

The ThreadID is used by Windows API functions to manipulate threads.  There is no need to reference the ThreadID property directly when calling Windows API functions which take a ThreadID as a parameter, as the ThreadID is the default property of the thread object.

 

Home Copyright and Disclaimer