ICustomQueryInterface..::.GetInterface Method Home
This page is specific to:.NET Framework Version:4.0
.NET Framework Class Library
ICustomQueryInterface..::.GetInterface Method

[This documentation is for preview only, and is subject to change in later releases. Blank topics are included as placeholders.]

Returns an interface according to a specified interface ID.

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

'Usage

Dim instance As ICustomQueryInterface
Dim iid As Guid
Dim ppv As IntPtr
Dim returnValue As CustomQueryInterfaceResult

returnValue = instance.GetInterface(iid, _
    ppv)

'Declaration

Function GetInterface ( _
    ByRef iid As Guid, _
    <OutAttribute> ByRef ppv As IntPtr _
) As CustomQueryInterfaceResult

Parameters

iid
Type: System..::.Guid%
The GUID of the requested interface.
ppv
Type: System..::.IntPtr%
A reference to the requested interface, when this method returns.

Return Value

Type: System.Runtime.InteropServices..::.CustomQueryInterfaceResult
One of the enumeration values that indicates whether a custom implementation of IUnknown::QueryInterface was used.
Remarks

An application can use managed code to specify its own implementation for custom interfaces and standard runtime interfaces.

The CustomQueryInterfaceResult return value can be used to enable or disable customized implementations by showing or hiding specific interfaces during COM access.

This method is invisible to COM.

.NET Framework Security

  • SecurityCriticalAttribute 

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

Platforms

Windows 7, Windows Vista, Windows XP SP2, Windows Server 2008, Windows Server 2003

The .NET Framework and .NET Compact Framework do not support all versions of every platform. For a list of the supported versions, see .NET Framework System Requirements.
Version Information

.NET Framework

Supported in: 4

.NET Framework Client Profile

Supported in: 4
See Also

Reference

© 2009 Microsoft Corporation. All rights reserved.   Terms of Use | Trademarks | Privacy Statement
Page view tracker
Rate the Lightweight library
x
Lightweight builds on ScriptFree (loband) by adding features you've requested: a SearchBox and default code language selection.
Do you like the SearchBox?
Do you like the tabbed code blocks?
How useful is this topic?
Tell us more.
Thanks
x
You're helping to improve MSDN Online.
Feedback
Switch View
Classic
Lightweight Beta
ScriptFree
Switch View