Windows Forms 2.0 Programming (Microsoft .NET Development Series)

9. Components

Packaging code into classes is an effective way to promote code reuse and save coding effort. VS05 and the Windows Forms Designer take this one step further by providing an infrastructure that trades a programmatic experience for a declarative one, enabling you to drag a class from the Toolbox onto a form and configure it using a host of Windows Forms Designer features, including the Properties window to set properties and manage event handlers. It takes a special type of class known as a component to use such support.

This chapter defines what components are, the capabilities they possess, and the ways in which you can use them, customize them, or create your own.

Категории