ShlwApiSHSetThreadRef Method
Stores a per-thread reference to a Component Object Model (COM) object.
This allows the caller to control the thread's lifetime so that it can ensure that
Windows won't shut down the thread before the caller is ready.
Namespace: DevCase.Win32.NativeMethodsAssembly: DevCase.net48 (in DevCase.net48.dll) Version: 6.0.0.0 (6.0)
XMLNS for XAML: Not mapped to an xmlns.
[DllImportAttribute("ShlwApi.dll", ExactSpelling = true)]
public static HResult SHSetThreadRef(
Object punk
)
<DllImportAttribute("ShlwApi.dll", ExactSpelling := true>]
Public Shared Function SHSetThreadRef (
punk As Object
) As HResult
Dim punk As Object
Dim returnValue As HResult
returnValue = ShlwApi.SHSetThreadRef(punk)
public:
[DllImportAttribute(L"ShlwApi.dll", ExactSpelling = true)]
static HResult SHSetThreadRef(
Object^ punk
)
[<DllImportAttribute("ShlwApi.dll", ExactSpelling = true)>]
static member SHSetThreadRef :
punk : Object -> HResult
No code example is currently available or this language may not be supported.
- punk Object
-
A pointer to the IUnknown of the object for which you want to store a reference. This value can be NULL.
HResult
If this function succeeds, it returns
S_OK.
Otherwise, it returns an
HResult error code.