137. Create a Form
BEFORE YOU BEGIN
Just jump right in!
138 Modify a Form
139 Enter Data Using a Form
To help you enter data into a complex table that contains a lot of fields , you can create a form to help you arrange those fields in a more compact and perhaps more logical order. Unlike entering data in List view, with a form, you can add instructions and informational text or graphics that make the form easier for someone else to enter the right data into the table.
If you think you might be entering the same information in multiple records, you can enter that data in a simple table with only one field, and then link to the resulting one-column list from the form. For example, to make entering the data for each CD in a music collection table easier, you might create a simple one column/field music categories table, with entries such as jazz, rock, country , and so on. You could then make this music category list available to the CD form, so when you use the form later on to enter your CD collection, you can select the music category for each CD from a list instead of having to type the various categories over and over again as you enter information about each CD.
137. Create a Form
If you want to create a simple list for use in the form, create the one-field table first , before creating the form. See 135 Create a Database , steps 59. Then enter the data for the single-column list using List view. See 136 Enter Data in List View .
Click the Forms button on the Database pane of the Base window.
Click Use Wizard to Create Form
Click the Use Wizard to Create Form link, shown in the Tasks list on the right side of the Base window. The Form Wizard appears.
| | Select Fields
In Step 1
of the Form Wizard,
select the table for which you're creating this form from the Tables or queries
list. The fields in that table appear in the Available fields
Select a field from the Available fields
list that you want to use on the form and click >
to add the field to the Fields in the form
list. Repeat to add each field to the Fields in the form
list. When you have identified all the fields you want to use in the form, click Next.
To use all the fields in the table on the form, click >> instead.
| | Arrange Controls
again to skip Step 2, Step 3,
and Step 4
(see Note for more information). In Step 5
of the Form Wizard
, click the button under the Arrangement of the main form
heading that represents the general layout you want for the data entry boxes on the form. After you click a button, the sample layout is displayed below the Form Wizard
, in the actual form window. This arrangement allows you to preview each layout until you find the one you like.
If you choose something other than the sheet layout (the third option), you can adjust the size and position of each control to suit your exact needs after the form is created. Click Next
If you want to be able to make changes to data in another table while entering data in this table, you can add a subform. This advanced feature is beyond the scope of this book. Steps 24 of the Form Wizard relate to the creation of a subform.
Set Data Entry Mode
In Step 6 of the Form Wizard , select the type of data entry mode you want and click Next . For example, if you intend to use the form to enter data but not to review it, choose The form is to be used for entering new data only. Existing data will not be displayed.
If you want the user to be able to scroll through previously entered records using the form, choose The form is to display all data. Then choose any restrictions you want by enabling the appropriate check box. For example, to prevent a user from deleting previous records, enable the Do not allow deletion of existing data option. Click Next.
Select a Background
In Step 7 of the Form Wizard , select the background color you want to use from the Apply styles list. Again, as you select a color, you can see a preview of how your color selection will look on the actual form under the Form Wizard .
Select how you want the border around each field to appear (such as 3D) from the Field border options on the right side of the wizard window. Click Next.
Name the Form
In Step 8 of the Form Wizard , type a name for the form in the Name of the form text box, or simply leave the suggested name as is.
To start entering data into your table using the form, choose Work with the form. (See 139 Enter Data Using a Form .) To make changes to the form before you use it, choose Modify the form. (See 138 Modify a Form .) Click Finish . The form is created and displayed in a window.