ShlwApiSHCreateThreadRef Method
Creates a per-thread reference to a Component Object Model (COM) object.
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 SHCreateThreadRef(
ref int refRef,
out Object refPunk
)
<DllImportAttribute("ShlwApi.dll", ExactSpelling := true>]
Public Shared Function SHCreateThreadRef (
ByRef refRef As Integer,
<OutAttribute> ByRef refPunk As Object
) As HResult
Dim refRef As Integer
Dim refPunk As Object
Dim returnValue As HResult
returnValue = ShlwApi.SHCreateThreadRef(refRef,
refPunk)
public:
[DllImportAttribute(L"ShlwApi.dll", ExactSpelling = true)]
static HResult SHCreateThreadRef(
int% refRef,
[OutAttribute] Object^% refPunk
)
[<DllImportAttribute("ShlwApi.dll", ExactSpelling = true)>]
static member SHCreateThreadRef :
refRef : int byref *
refPunk : Object byref -> HResult
No code example is currently available or this language may not be supported.
- refRef Int32
-
A pointer to a value, usually a local variable in the thread's ThreadProc,
that is used by the interface in refPunk as a reference counter.
- refPunk Object
-
The address of a pointer to an IUnknown interface.
If successful, this parameter holds the thread's IUnknown pointer on return.
Your application is responsible for freeing the pointer when it is finished.
HResult
If this function succeeds, it returns
S_OK.
Otherwise, it returns an
HResult error code.