Export (0) Print
Expand All

SafeHandle.SetHandle Method

Sets the handle to the specified pre-existing handle.

Namespace: System.Runtime.InteropServices
Assembly: mscorlib (in mscorlib.dll)

protected void SetHandle (
	IntPtr handle
)
protected void SetHandle (
	IntPtr handle
)
protected function SetHandle (
	handle : IntPtr
)
Not applicable.

Parameters

handle

The pre-existing handle to use.

Use the SetHandle method only if you need to support a pre-existing handle (for example, if the handle is returned in a structure) because the .NET Framework COM interop infrastructure does not support marshaling output handles in a structure.

Windows 98, Windows Server 2000 SP4, Windows Millennium Edition, Windows Server 2003, Windows XP Media Center Edition, Windows XP Professional x64 Edition, Windows XP SP2, Windows XP Starter Edition

The Microsoft .NET Framework 3.0 is supported on Windows Vista, Microsoft Windows XP SP2, and Windows Server 2003 SP1.

.NET Framework

Supported in: 3.0, 2.0

Community Additions

ADD
Show:
© 2014 Microsoft