Skip to Content
Programming Visual Basic .NET
book

Programming Visual Basic .NET

by Dave Grundgeiger
December 2001
Beginner
464 pages
13h 51m
English
O'Reilly Media, Inc.
Content preview from Programming Visual Basic .NET

Chapter 5. Windows Forms II: Controls, Common Dialog Boxes, and Menus

By themselves, one or more forms provide very little functionality to most desktop applications. For the most part, forms are valuable insofar as they serve as containers for controls. In this chapter, we’ll complete our discussion of building desktop applications by focusing on the objects that forms contain—in particular, controls and components, common dialogs, and menus.

Common Controls and Components

This section contains a summary of the controls and components defined in the System.Windows.Forms namespace. Components are classes derived from the Component class (defined in the System.ComponentModel namespace). They may or may not provide a visual interface. They are often used as elements of forms but don’t have to be. Controls are classes derived from the Control class (defined in the System.Windows.Forms namespace). Controls generally are used to build the visual appearance of a form. The Control class itself is derived from the Component class, so controls are also components.

The common dialog boxes are not listed here, even though they all derive from the Component class. They are given their own section, Section 5.4 later in this chapter.

The Button Class

This class represents a button control, which is one of the most commonly used controls in Windows applications. The Button class’s Click event, which it inherits from Control, is its most commonly used event.

The Button class inherits two important ...

Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Start your free trial

You might also like

Programming Visual Basic .NET, Second Edition

Programming Visual Basic .NET, Second Edition

Jesse Liberty

Publisher Resources

ISBN: 0596000936Supplemental ContentCatalog PageErrata