Combo Box synchronization

  • Thread starter Thread starter George Delaware
  • Start date Start date
G

George Delaware

Guest
Hi, I know there have been a number of posts regarding this, but I've tried many methods and nothing is working for me.

I am using the Order Entry database that comes with ms access. The wizard generates all the relationships etc.

I've tried http://support.microsoft.com/support/kb/articles/Q209/5/76.ASP?LN=EN-US&SD=gn&FR=0&qry=q209576&rnk=1&src=DHCS_MSPSS_gn_SRCH&SPR=ACC2000

and it does not work with the Order Entry db. I've tried countless times. I was wondering if anyone could either test it or help me to get this thing working. I've been at it for quite some time now.

when i enter the code provided by the above link, when i choose the second drop down box, it displays everything. Not what just corresponds to box number one.

I am making a sample db for a restaurant. So when you choose Beef, all the beef dishes should appear in the second drop down box. Problem is, is that it doesn't.
smile.gif


All of the menu items appear.

Does anyone know what I'm doing wrong? Thanks very much!

-George
 
"Solutions" sample db has examples of sychronized combo boxes.
 
There are two things that you need to do to synchronize two comboboxes. In the query for combo2, refer to combo1 as selection criteria:

Where SomeField = Forms!YourFormName!YourCombo1Name;

And in the AfterUpdate event of combo1, you need to requery combo2 to get it to refresh.

Me.YourCombo2Name.Requery
 
Thanks for replying.

I've tried that, however I choose Combo Box number one, and then when I go to Combo Box number 2, it is blank.

i've double checked the names to make sure they match, and the queries.
??
 
Make sure that you are putting the criteria in the correct field. Generally speaking, the value of a combo is the first (normally hidden) column. This is normally an ID. Check the recordsource of the first combo (if it is a query, check which is the first shown field - this is the value of your combo)
make the sure the criteria for the field you want to filter is =Forms!YourFormName!YourCombo1Name

HTH
 
I was using access xp. So i decided to try the microsoft tutorial in Access 2000, which was similar to your guys' suggestions.

It worked!Thanks for all your help.
 
Hi!

I'm currently developing a restaurant project, and I'm running into the same trouble you did. How did you solve it? I'd highly appreciate a sample db!
thanks!!
 
Follow the directions I posted. Cascading the combos requires only two things. Look at the northwind or orders sample databases that shipped with your version of Access for an example.
 

Users who are viewing this thread

Back
Top Bottom