Both classes and components are units of reusable code. To author a component, you start with a class. A class becomes a component when it conforms to a standard for component interaction. This standard is provided through the IComponent interface. Any class that implements the IComponent interface is a component. For details about interfaces, seeand . Such standards allow developers to plug components together quickly to create larger programs. The common language specification (CLS) describes the way components authored for the common language runtime can interact. For details, see
The .NET Framework provides the IComponent interface and the Component base class to make it easy to author components that work well in the design environment, andand classes that make it easy to author visual components.
In This Section
Introduces class attributes and what they mean for a component class.
Explains where to write the code to initialize your component, dispose of system resources, and destroy your component.
Describes differences in component creation between earlier and later versions of Visual Basic.