Mr Lowe's Lessons...
Plough Farm Database Instructions - Handling Data
Modifying the Bookings Form with a Combo Box
This second stage adds a "Combo" box to the booking
form to look up the customer who is making a booking.
A combo box is a drop down list of options that you can choose
from
HOW TO DO IT
- Open up your database from My Documents if you haven't already
done so
- Go in to Forms and open up the "frmbookings" form
in design view
- Make the window bigger so that you can see all the available
parts of the form
- Select the customer number lable and press delete then
select the customer number control and press delete.
- Then click once on the "combo box" button on
the tool box (if the tool box is not visible it is easy to locate it)
- Then click on your form where you want to combo box to
go. You can move it later if you wish.
- In the next window select that you wish to look up a value
in a table or query. Then click Next
- In the next window choose the table "tblcustomers"
and then click Next
- Click on the > button to move the Customer Number field,
the First Name and the Second Name fields to the right hand part of the screen
which is the selected fields list. Then Click Next
- Choose to sort the order ascending by surname in the next
window then click Next
- Then un-tick the "hide key column" box in the
next window and click Next
- In the next window select Customer Number as a value to
store and then click Next
- Select "store this value in this field" option
and choose the "customer number" field before you click Next
- Label the combo box "Select a Customer" and then
click Finish
- You can then click on the "save" icon on the top
tool bar. Put your form in to "view" mode and see if it works...
You can now do a similar thing to set up a combo box to look
up the values in the "accomodation type" field
This is the third step in setting up the Bookings Form
BACK TO MAIN PAGE