Microsoft Access 2010 Bible

(Rick Simeone) #1

Part I: Access Building Blocks


270


FIGURE 7.16

Drag fields from the Field List to add bound controls to the form.


You can see four new controls in the form’s Design view — each one consists of a Label control and a
Text Box control (Access attaches the Label control to the text box automatically). You can work with
these controls as a group or independently, and you can select, move, resize, or delete them. Notice
that each control has a label with a caption matching the field name, and the Text Box control dis-
plays the bound field name used in the text box. If you want to resize just the control and not the
label, you must work with the two controls (label and associated text box) separately.

Close the Field List by clicking the Add Existing Fields command in the ribbon’s Tools group or
the Close button on the Field List.

Tip
In Access, you can change the type of control after you create it; then you can set all the properties for the
control. For example, suppose that you add a field as a Text Box control and you want to change it to a List
Box. Right-click the control and select Change To from the pop-up menu to change the control type. However,
you can change only from some types of controls to others. You can change almost any type of control to a
Text Box control, while option buttons, toggle buttons, and check boxes are interchangeable, as are List Box
and Combo Box controls.


In the “Introducing Properties” section, later in this chapter, you learn how to change the control
names, captions, and other properties. Using properties speeds the process of naming controls and
binding them to specific fields. If you want to see the differences between bound and unbound
controls, switch to Form view using the View command in the ribbon’s View group. The
Description, Category, RetailPrice, and Cost controls display data because they’re
bound to tblProducts. The other three controls don’t display data because they aren’t bound to
any data source.
Free download pdf