Kernel32SetThreadDescription Method

Assigns a description to a thread.

Definition

Namespace: DevCase.Win32.NativeMethods
Assembly: DevCase.net48 (in DevCase.net48.dll) Version: 6.0.0.0 (6.0)
XMLNS for XAML: Not mapped to an xmlns.
[DllImportAttribute("Kernel32.dll", CharSet = CharSet.Unicode, ExactSpelling = true)]
public static HResult SetThreadDescription(
	IntPtr hThread,
	string threadDescription
)

Parameters

hThread  IntPtr
A handle for the thread for which you want to set the description. The handle must have SetLimitedInformation access.
threadDescription  String
A Unicode string that specifies the description of the thread.

Return Value

HResult
If the function succeeds, the return value is the HResult that denotes a successful operation.

If the function fails, the return value is an HResult that denotes the error.

Remarks

See Also