CreateAggregatedObject Method (IntPtr, Object)
Collapse the table of content
Expand the table of content

Marshal.CreateAggregatedObject Method (IntPtr, Object)

 

Aggregates a managed object with the specified COM object.

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

[SecurityCriticalAttribute]
public static IntPtr CreateAggregatedObject(
	IntPtr pOuter,
	object o
)

Parameters

pOuter
Type: System.IntPtr

The outer IUnknown pointer.

o
Type: System.Object

An object to aggregate.

Return Value

Type: System.IntPtr

The inner IUnknown pointer of the managed object.

Exception Condition
ArgumentException

o is a Windows Runtimeobject.

The CreateAggregatedObject method aggregates the inner managed pointer of a managed object with the specified outer pointer, and then returns an inner IUnknown pointer of the managed object.

SecurityCriticalAttribute

requires full trust for the immediate caller. This member cannot be used by partially trusted or transparent code.

Universal Windows Platform
Available since 4.5
.NET Framework
Available since 2.0
Portable Class Library
Supported in: portable .NET platforms
Windows Phone
Available since 8.1
Return to top
Show:
© 2016 Microsoft