Desktop Functions:

   Smart Device Functions:

Show Recent Changes
Subscribe (RSS)
Misc. Pages
Helpful Tools
Suggested Reading
Website TODO List
Support Forum
Download Visual Studio Add-In

Terms of Use
Privacy Policy
IUnknown (Interfaces)
Base interface that all other COM interfaces inherit from. Defines the standard reference counting and interface discovery mechanisms for COM objects.

C# Signature:

    [ComImport, InterfaceType(ComInterfaceType.InterfaceIsIUnknown), Guid("00000000-0000-0000-C000-000000000046")]
    public interface IUnknown
    IntPtr QueryInterface(ref Guid riid);

    UInt32 AddRef();

    UInt32 Release();

VB Signature:

<ComVisible(False)> _
<ComImport()> _
<InterfaceType(ComInterfaceType.InterfaceIsIUnknown)> _
<Guid("00000000-0000-0000-C000-000000000046")> _
Public Interface IUnknown
     Function QueryInterface(ByRef riid As Guid) As IntPtr

     <PreserveSig()> _
     Function AddRef() As Integer

     <PreserveSig()> _
     Function Release() As Integer
End Interface

User-Defined Types:



It is usually not necessary to call IUnknown's methods directly in your .NET code. The interop runtime code will insert the appropriate method calls for reference counting when the managed proxy objects are created and freed, and will translate typecast, "is", and "as" operators into calls to QueryInterface.

IUnknown on MSDN

Please edit this page!

Do you have...

  • helpful tips?
  • corrections to the existing content?
  • alternate definitions?
  • additional languages you want to include?

Select "Edit This Page" on the right hand toolbar and edit it! Or add new pages containing any supporting types needed.

Access directly from VS:
Terms of Use
Edit This Page
Find References
Show Printable Version