New To Access and having trouble with synchronized fields

A

AnnieV

I hope someone can help me. I am pretty new to access and am building a form
that uses synchronized combo boxes. I am able to make it work using 2 boxes.
i.e., Customer Name and Ownership Codes. I’m having problems when I try to
set a similar scenario up for three or more choices. I want to set it up so I
get cascading information for categories, equipment, and levels. If the user
clicks on a category, i.e., Engines, then I want to see associated equipment
information populated in the second box. When the user chooses the equipment
type I want them to then be able to choose the levels based on the
engine/equip choice they made. I have 7 different categories and 50+ types of
equipment and levels. The equipment and levels contain different information
but all 3 things need to tie. I hope this is making sense. I am confusing
myself trying to get this to work and think I may be making it harder then it
has to be. Can someone help me?
 
S

Steve

First of all you need the right tables:
TblCategory
CategoryID
Category

TblEquipment
EquipmentID
CategoryID
Equipment

TblLevel
LevelID
EquipmentID
Level

You need three queries for your combobox. For the first combobox, the query
is based on TblCategory. For the second combobox, the query is based on
TblEquipment. For the third combobox, the query is based on TblLevel. In the
second query, put the following expression in the criteria of CategoryID:
Forms!NameOfYourForm!NameOfFirstCombobox. In the third query, put the
following expression in the criteria of EquipmentID:
Forms!NameOfYourForm!NameOfSecondCombobox.

Put the following code in the Enter event of the First combobox:
Me!NameOfFirstCombobox.DropDown

Put the following code in the AfterUpdate event of the first combobox:
Me!NameOfSecondCombobox = Null
Me!NameOfSecondCombobox.Requery
Me!NameOfThirdCombobox = Null


Put the following code in the Enter event of the second combobox:
Me!NameOfSecondCombobox.DropDown

Put the following code in the AfterUpdate event of the second combobox:
Me!NameOfThirdCombobox = Null
Me!NameOfThirdCombobox.Requery

Put the following code in the Enter event of the third combobox:
Me!NameOfThirdCombobox.DropDown

PC Datasheet
Providing Customers A Resource For Help With Access, Excel And Word
Applications
(e-mail address removed)
 
A

AnnieV via AccessMonster.com

Thank you very much! It worked. I appreciate your help with this.
 
A

AnnieV via AccessMonster.com

Thank you very much. I was able to get this to work. I really appreciate your
help.
 
G

Guest

Dear Steve

I am also very new to MS Access.

I followed this reply see below of yours

My situation is similar but I only have 2 Combo Boxes 10 & 12

TBL: Ingredient Catagory
Ingredient_Cat

TBL: Ingredients
ID
Ingredient_Cat
Ingredient_Description

I did the queries and the code as below.

Combo box 10 wroks and gives me a list of the catagories but when I click in
Combo box 12 it requests a Parameter value: Forms:Rec_Ing Subform!Combo10

Now I am stuck, Please help

Thank you

Esrei
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top