Multiple Filters on one subform

dgaller

Registered User.
Local time
Today, 16:41
Joined
Oct 31, 2007
Messages
60
I currently have code on click to filter a subform based on a combo box and it works great. (see below)

Me.[task detail subform].Form.Filter = "[Person Responsible] =" & Me!Combo107
Me.[task detail subform].Form.FilterOn = True

The problem is I also need to only show records that have a 1, 2 or 3 in the status field on the same report.

How do I join that to the above filter?
 
Just wrap the pcs in parens and joing them with 'and'.


:)
ken
 
I tried doing :
Me.[task detail subform].Form.Filter = "[Person Responsible] =" & Me!Combo107 And Me.[task detail subform].Form.Filter = "[status] =1" but I get a type mismatch error. Status is a field I have a look up to. (Example 1 = open)
 
Me.[task detail subform].Form.Filter = "([Person Responsible] =" & Me!Combo107 & ") And ([status] =1)"

or

Me.[task detail subform].Form.Filter = "([Person Responsible] =" & Me!Combo107 & ") And ([status] ='1')"


???
ken
 
It worked. I truly appreciate your help, Ken!
 

Users who are viewing this thread

Back
Top Bottom