Chapter 8. Selecting Windows Forms Controls

Controls are an extremely important part of any interactive application. They give information to the user (Label, ToolTip, TreeView, PictureBox) and organize the information so that it's easier to understand (GroupBox, Panel, TabControl). They enable the user to enter data (TextBox, RichTextBox, ComboBox, MonthCalendar), select options (RadioButton, CheckBox, ListBox), control the application (Button, MenuStrip, ContextMenuStrip), and interact with objects outside of the application (OpenFileDialog, SaveFileDialog, PrintDocument, PrintPreviewDialog). Some controls also provide support for other controls (ImageList, ToolTip, ContextMenuStrip, ErrorProvider).

This chapter provides only a very brief description of the standard Windows Forms controls and some tips that can help you decide which control to use for different purposes. Appendix G covers the controls in much greater detail, describing each control's most useful properties, methods, and events.

Controls Overview

Figure 8-1 shows the Visual Basic Toolbox displaying the standard Windows Forms controls. Because you can add and remove controls on the Toolbox, you may see a slightly different selection of tools on your computer.

The following table briefly describes the controls shown in Figure 8-1 in the order in which they appear in the figure (starting at the top, or row 1, and reading from left to right).

Figure 8-1. Visual Basic provides a large number of standard controls for Windows ...

Get Visual Basic® 2008 Programmer's Reference now with O’Reilly online learning.

O’Reilly members experience live online training, plus books, videos, and digital content from 200+ publishers.