Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations derfloh on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

changing selection of a drop down box depending on condition

Status
Not open for further replies.

astraltango

Programmer
Joined
Nov 19, 2003
Messages
18
Location
AU
I've having trouble restricting the selection of a drop down box depending on certain conditions (ie, depending on the value of another field).

For example: If "A" is chosen in drop down box 1, I want the selection of drop down box 2 to be "queryA". If "B" is chosen in drop down box 1, I want the selection of drop down box 2 to be "queryB" etc.

I assume this has already been discussed, so I would be grateful if someone could refer me to an appropriate thread or website.

Cheers
 
In the Got Focus event of box 2 you can put...

If Me.Box1 = "A" Then
Me.Box2.RowSource = "queryA"
ElseIf Me.Box1 = "B" Then
Me.Box2.RowSource = "queryB"
End If



ProDev, MS Access Applications
Visit me at ==> Contact me at ==>lonniejohnson@prodev.us

May God bless you beyond your imagination!!!
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top