Based on a combo box selection

  • Thread starter Thread starter Raashid
  • Start date Start date
R

Raashid

I'm using Access and I need to figure out how to display
the record details based on a combo box selection. For
example, when I select a CustomerID in a combo box, how do
I get the related customer name and address information to
appear?

Regards
Raashid
 
Raashid

One way to do this is to create a query of the underlying table that holds
the name/address info. As a criterion in that query, use an expression to
point to the combo box in the form for the CustomerID parameter value,
something like:

Forms!YourFormName!cboYourComboBoxName

Base the form on the query.

Make sure the combo box is NOT bound to the CustomerID data field. Make
sure the combo box does NOT have a default value.

In the AfterUpdate event of the combo box, requery the form with something
like:

Me.Requery
 
Back
Top