Are you sure you don't want a report for this? A subform connotes data enrtry. If you want to display a certain period of time, you would do that in a report.
In any event, base the subform on a query, and put the following criteria in the period field:
BETWEEN [Forms]![frmYourMainFormName].[FromPeriod] AND [Forms]![frmYourMainFormName].[ToPeriod]
When the subform opens, it should contain only those values in the period.
Be sure to set the Parent Child link on the subform to the Account No.
Did that work?
mmcdonal
|