IDebugSystemObjects4::GetThreadIdByHandle method

The GetThreadIdByHandle method returns the engine thread ID for the specified thread. The thread is specified by its system handle.

Syntax

HRESULT GetThreadIdByHandle(
  ULONG64 Handle,
  PULONG  Id
);

Parameters

Handle

Specifies the system handle of the thread whose thread ID is requested.

Id

Receives the engine thread ID.

Return Value

This method may also return error values. See Return Values for more details.

Return code Description
S_OK
The method was successful.

Remarks

In kernel-mode debugging, because the handle is an artificial handle for a processor, this method returns the engine thread ID for the virtual thread representing that processor.

For more information about threads, see Threads and Processes. For details on system handles, see Handles.

Requirements

   
Target Platform Desktop
Header dbgeng.h (include Dbgeng.h)