Subform Filter

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

Hello,
I have a form named "frm_Customers" with a subform named "sub_Comments".

I am trying to open frm_customers using a filter on a field in
"sub_Comments" called "follow_up_date". (anything with follow-up date expired)

I am trying to open from a button on different form using the docmd.opeform
statement. Any way to open using a filter on a subform?
 
See:
Filter a Form on a Field in a Subform
at:
http://allenbrowne.com/ser-28.html

The article suggests setting the RecordSource of the main form to an INNER
JOIN statement, so you can use the follow_up_date field in the related table
as your criteria.

An alternative (but less efficient) approach would be to use a subquery in
the WhereCondition of OpenForm. If you want to explore that idea also,
here's an introduction to subqueries:
http://allenbrowne.com/subquery-01.html
 
Great article! Thanks for your help Allen! You've answered several of my
posts in the past and your expert help is always greatly appreciated!

Luke
 
Back
Top