Microsoft Office Tutorials and References
In Depth Information
The toolbox contains a useful assortment of controls that can be placed on a form. Some,
like the Label control, are static and merely modify how the form appears. Other controls,
such as the Te xtBox and the CommandButton , interact with the user to edit information and
In addition to displaying the form, the Visual Basic Editor also displays a floating toolbar
called the toolbox . The toolbox contains the list of controls that can be placed on a form.
To add a control to the form, select the control from the toolbox, drag it onto the form, and
drop it where you want the control. You can adjust the size and placement of the control
graphically by selecting the control and dragging the control around or by dragging the box
that surrounds the control. (See Figure 19-2.)
Figure 19-2. You add controls to a form control by selecting a control and dragging and
dropping it on the form.
All of the code associated with the form and its controls are stored in the form module.
This is an independent element much like a regular module or a class module. Double-click
ing a control will switch you from the graphical view of the form to the code view of the form
and automatically insert the subroutine definition for the default event for that control.