Tables are Assets, Category, Make and Model.
Queries are Make Query and Model Query.
Form is Asset Details.
First combo box is cboCategory that pulls from the Category table. It has an AfterUpdate event to requery the cboManufacturer combo box. Coded like this:
Expand|Select|Wrap|Line Numbers
- Private Sub cboCategory_AfterUpdate()
- Me.cboManufacturer.Requery
- End Sub
Expand|Select|Wrap|Line Numbers
- SELECT Make.MakeID, Make.Make, Make.Category
- FROM Make
- WHERE (((Make.Category)=[Forms]![Asset Details]![Category]))
- ORDER BY Make.Make;
Expand|Select|Wrap|Line Numbers
- Private Sub cboManufacturer_AfterUpdate()
- Me.cboModel.Requery
- End Sub
Third combo box is cboModel that uses the Model Query to look at cboManufacturer to determine what to show. SQL looks like:
Expand|Select|Wrap|Line Numbers
- SELECT Model.ModelID, Model.Model, Model.Make
- FROM Model
- WHERE (((Model.Make)=[Forms]![Asset Details]![Manufacturer]))
- ORDER BY Model.Model;
I have attached a copy of a simplified version of the database. I am in the process of modifying a template and still weeding out parts I don't need. So far everything else works fine.
Any help is appreciated. Thanks.
Marc