View Full Version : Subforms- Stumped!


Rjc8513
10-11-2001, 08:21 AM
I'm stumped! I have a form named [frm ARCHIVE] that has the query [qry ARCHIVE] as it's record source. On the form I have a combo box [cbx UNIT] which uses Recordset.Clone to display the selected unit's data in a subform [frm ARCHIVE SUB] on the main form. The subform also has the query [qry ARCHIVE] as it's record source.

It works just fine. When the user selects a unit from the combo box, the data for that unit is displayed in the subform. But, now I have added two more combo boxes [cbx BegDate] and [cbx EndDate] to the main form so that the user can select a range of dates. Then I want all the data for the previously selected unit ONLY for the selected date range to be displayed in the subform.

Can't get it right. Any suggestions? Thanks.

llkhoutx
10-11-2001, 10:46 AM
You're not referencing the date control on the form from you subform's recordsource query correctly.

Use the expression builder to build the criteria for your subform's recordsource.