patrick444
11-29-2001, 11:36 AM
I have two Access2000 combo boxes, each based upon a query. I want to filter the contents of the second combo box, based upon what is chosen in the first. I can do this by entering the value from the first combo box into the criteria field of the second query, but if the user changes her mind and changes the value in the first combo box, the second combo box still displays the list for the first choice. How do I make the second list dependent upon whichever value is currently in the first box, not just on the original committed value?
David R
11-29-2001, 12:15 PM
I believe this will answer what you want to do (the part you were missing was probably the Requery):
Posted by Travis, Member
posted 01-11-2000 12:23 AM
---------------------------------------------
on the AfterUpdate of the first field, change the rowsource of the second field like this.
Me.[SecondField].Rowsource="Select * from [table] where ID=" & Me.[FirstField]
Me.[secondfield].requery
---------------------------------------------
David R
11-29-2001, 12:17 PM
FYI, I found this (because I'd seen it before, but the principle is the same) by entering 'linked combo boxes' into the search page for the Forms forum. It's an amazing resource database (IMO, it beats Microsoft's support page hands down).
"If I have seen further, it is because
I have stood on the shoulders of giants..."
David R.