Name
COMClass Attribute — Microsoft.VisualBasic.COMClassAttribute
Description
Adds metadata that allows a .NET class to be exposed as a COM object. You can supply the attribute with a class identifier, an interface identifier, and an event identifier. All are globally unique identifiers (GUIDs) that can be generated either by using the guidgen.exe utility or automatically by using the COM Class Wizard. They ensure that the COM component retains the same GUIDs when it is recompiled.
Constructor
New([[[classID
],interfaceID
],eventID
])
classID
StringThe class identifier (CLSID) that will uniquely identify the COM class
interfaceID
StringThe interface identifier (IID) that uniquely identifies the class’ default COM interface
eventID
StringThe event identifier that uniquely identifies an event
Properties
- ClassID String
Read-only. Provides the CLSID that uniquely identifies a COM class. Its value is set by the
classID
parameter of the class constructor.- EventID String
Read-only. Provides the GUID that uniquely identifies an event. Its value is set by the
eventID
parameter of the class constructor.- InterfaceID String
Read-only. Provides the IID that uniquely identifies a COM interface. Its value is set by the
interfaceID
parameter of the class constructor.- InterfaceShadows Boolean
Indicates whether the COM interface name is the same as the name of another member of the class or the base class. Its default value is
False
.
Get VB.NET Language Pocket Reference now with the O’Reilly learning platform.
O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.