More About Forms
More About Forms
Grade 11
Topic: Database Management
Specific Objectives
• When you use the Form command on an existing table, all of the fields
from the table are included in the form. However, if you later add
additional fields to the table, these fields will not automatically show up
in existing forms. In situations like this, you can add additional fields to a
form.
To add a field to a form:
1 Select the Design tab, then locate the Tools group on the
ALL Tables
Design controls set restrictions on the fields in your forms. This helps you better control how
the data is entered into your forms, which in turn helps keep the database consistent.
Combo boxes
• A combo box is a drop-down list you can use in your form in place of a field. Combo boxes limit the information users
can enter by forcing them to select only the options you have specified.
• Combo boxes are useful for fields that have a limited number of possible valid responses. For instance, you might use a
combo box to make sure people only choose products that already exist in your database while placing an order.
To create a combo box:
1 In Form Layout view, select the Design tab, then locate the
Controls group..
between the City field and the Add to Mailing List? fields.
The Combo Box Wizard dialog box will appear. Select I will type in the values that I want, then
4
click Next.
Type the choices you want to appear in your drop-down list. Each choice should be on its own row.
5
In our example, users will be able to select one of three choices from our finished combo box: No,
NB. If necessary, resize the column so all of your text is visible. Once you are
click Next.
Enter the label—or name—that will appear next to your combo box.
7
Generally, it's a good idea to use the name of the field you chose in the
previous step.
Click Finish. Your combo box will appear on the form. If you created your combo box to replace an
8
existing field, you should delete the first field.
In our example, you might notice that we now have two fields with the same name. These two fields
send information to the same place, so we don't need them both. We'll delete the one without the
combo box.
Switch to Form view to test your combo box. Simply click the drop-down arrow and verify that the
9
list contains the correct choices. The combo box can now be used to enter data.
If you want to include a drop-down list with a long list of options and don't want to type all of
NB
them out, create a combo box and choose the first option in the Combo Box Wizard: I want the
combo box to get the values from another table or query. This will allow you to create a drop-
down list from a table field.
Challenge yourself!!
Apply what you have learnt to your forms created in Bookshop database.
Manipulate data in a database (Queries)