Filter an Access Subform with Cascading Combo Boxes
Question details
Configure two cascading combo boxes to filter the records displayed in a Microsoft Access datasheet subform.

- Product
- Microsoft Access
- Device & OS
- not provided
- Scenario
- A user selects a value in the first combo box, then selects a related value in the second combo box to filter a datasheet subform.
- Observed behavior
- The combo boxes work together, but selecting the second value does not update the datasheet subform.
Open the parent form in Design View and identify the names of both combo box controls and the subform control. Check the table and field names used to relate the selections to the records you want to display.
Requery the cascading combo box and datasheet subform
Use form controls as query criteria and refresh the dependent controls in each combo box's After Update event.
The example assumes a parent form named frmFilter, unbound combo boxes named cboFirst and cboSecond, and a subform control named subRecords. Replace these names and the example table and field names with your own.
The example uses numeric IDs. Configure each combo box so its bound column returns the ID used by the queries. The subform may show no records until both selections have values.
In Design View, select cboSecond and open Property Sheet > Data > Row Source. Enter: SELECT SecondID, SecondName FROM tblSecond WHERE FirstID = Forms!frmFilter!cboFirst ORDER BY SecondName; Set Bound Column to 1 so the selected value is SecondID.
Open the form used by the datasheet subform in Design View. In its Property Sheet, set Data > Record Source to: SELECT * FROM tblRecords WHERE FirstID = Forms!frmFilter!cboFirst AND SecondID = Forms!frmFilter!cboSecond; Save the subform.
On the parent form, select cboFirst and choose Property Sheet > Event > After Update. Select [Event Procedure], click the build button (...), and add these lines inside cboFirst_AfterUpdate: Me!cboSecond = Null; Me!cboSecond.Requery; Me!subRecords.Form.Requery. Put each statement on a separate line in the VBA editor without the semicolons.
Select cboSecond and choose Property Sheet > Event > After Update > [Event Procedure]. Click (...) and add Me!subRecords.Form.Requery inside cboSecond_AfterUpdate.
Save the parent form and switch to Form View. Choose a first value, then a second value, and confirm that the datasheet shows matching records. Change the first value and check that the second selection clears before you choose a new one.

Work with filtered data in WPS Spreadsheets
WPS Office is a free, lightweight alternative for everyday document and spreadsheet work. Its familiar interface and Microsoft Office format compatibility make it easy to move existing files. WPS Spreadsheets can filter tabular data, but it does not fix Access forms or replace this Access subform setup.

Frequently Asked Questions
Why does the subform not change when I select the second combo box?
The subform needs to run its query again after the selection changes. In the second combo box's Property Sheet > Event > After Update, add an event procedure containing Me!subRecords.Form.Requery, using your subform control's name.
Why should I clear the second combo box when the first selection changes?
The previous second selection may not belong to the new first selection. In the first combo box's After Update event, set the second combo box to Null before calling its Requery method.
What if Access asks for a parameter when the form opens?
Check the form, control, table, and field names in the Row Source and Record Source SQL. A reference such as Forms!frmFilter!cboFirst also requires the named parent form to be open.
Can the subform be empty until both values are selected?
Yes. With both combo box values used as equality criteria, the example query may return no records while either value is Null. Select both values in Form View to display matching records.




