THREADENTRY32 structure

Describes an entry from a list of the threads executing in the system when a snapshot was taken.

Syntax

typedef struct tagTHREADENTRY32 {
  DWORD dwSize;
  DWORD cntUsage;
  DWORD th32ThreadID;
  DWORD th32OwnerProcessID;
  LONG  tpBasePri;
  LONG  tpDeltaPri;
  DWORD dwFlags;
} THREADENTRY32;

Members

dwSize

The size of the structure, in bytes. Before calling the Thread32First function, set this member to sizeof(THREADENTRY32). If you do not initialize dwSize, Thread32First fails.

cntUsage

This member is no longer used and is always set to zero.

th32ThreadID

The thread identifier, compatible with the thread identifier returned by the CreateProcess function.

th32OwnerProcessID

The identifier of the process that created the thread.

tpBasePri

The kernel base priority level assigned to the thread. The priority is a number from 0 to 31, with 0 representing the lowest possible thread priority. For more information, see KeQueryPriorityThread.

tpDeltaPri

This member is no longer used and is always set to zero.

dwFlags

This member is no longer used and is always set to zero.

Requirements

   
Minimum supported client Windows XP [desktop apps only]
Minimum supported server Windows Server 2003 [desktop apps only]
Header tlhelp32.h

See also

Thread32First

Thread32Next