ComboBox output depends on another won't work

A

ArkBob

I have a cbo pulling primary listing and then another cbo pulling info based
on the first cbo. I works the first time correctly but if I change the
selection in the first cbo the inform displayed in the second cbo does not
change. How do I force the second cbo to re-query based on the changed input
from the first?

Thanks
 
S

strive4peace

on the AfterUpdate event of the first combo:

'~~~~~~~~~~
me.combo2_controlname.Requery
me.combo2_controlname = null
'~~~~~~~~~~

the reason you want to clear the second combo is because if it has a
value that doesn't match the new criteria, it will not show and the user
will not realize it is filled out!

Warm Regards,
Crystal

remote programming and training

Access Basics
8-part free tutorial that covers essentials in Access
http://www.AccessMVP.com/strive4peace

*
:) have an awesome day :)
*
 
A

ArkBob

Thank you very much! Worked great.

strive4peace said:
on the AfterUpdate event of the first combo:

'~~~~~~~~~~
me.combo2_controlname.Requery
me.combo2_controlname = null
'~~~~~~~~~~

the reason you want to clear the second combo is because if it has a
value that doesn't match the new criteria, it will not show and the user
will not realize it is filled out!

Warm Regards,
Crystal

remote programming and training

Access Basics
8-part free tutorial that covers essentials in Access
http://www.AccessMVP.com/strive4peace

*
:) have an awesome day :)
*
 
Top