Programming with Components
Caution
This content was written for .NET Framework. If you're using .NET 6 or a later version, use this content with caution. The designer system has changed for Windows Forms and it's important that you review the Designer changes since .NET Framework article.
The designer architecture in Visual Studio lets you assemble non-visual component classes as easily as you assemble Visual Basic forms. The following sections explain how to create your own components, and how to assemble them from the sophisticated components in the .NET Framework classes.
This section defines what a component is and provides an overview of .NET Framework programming concepts that are especially relevant to component programming. While the term component has many meanings, in the .NET Framework a component is a class that implements the System.ComponentModel.IComponent interface or one that derives directly or indirectly from a class that implements this interface. The default base class implementation of the IComponent interface is System.ComponentModel.Component.
If you want your components and controls to be usable from other programming languages, you must author them in a Common Language Specification (CLS)-compliant language and ensure that all public and protected members are CLS-compliant. The Windows Software Development Kit (SDK) provides compilers for the following CLS-compliant languages: Visual Basic, C#, and C++. For more information about the CLS, see Language Independence and Language-Independent Components.
In This Section
Programming with Components How-to and Walkthrough Topics
Lists links to how-to and walkthrough topics contained in this sectionClass vs. Component vs. Control
Provides definitions for the terms component and control.Component Authoring
Describes component architecture, terminology, design, and implementation.
Related Sections
Extending Design-Time Support
Provides links to topics about integrating components and controls into the design environment.Overview of the .NET Framework
Provides links to introductory topics about the common language runtime, managed code, and other essential concepts.Developing Custom Windows Forms Controls with the .NET Framework
Provides links to topics about authoring custom Windows Forms controls.Developing Windows Forms Controls at Design Time
Provides links to topics about authoring Windows Forms controls at design time.Developing Custom ASP.NET Server Controls
Provides links to topics about authoring custom ASP.NET controls.