Me.Filter - 2 criteria

B

BMaerhofer

I have a form with a button to show only active records (without a closed
date or reported date). I need for it to show only the records that
Act_Complete is null and Reported_Date is null. I have tried many different
types of VBA and had had no luck:

'Me.Filter = "Act_Complete is null"
'Me.FilterOn = True
'Me.Filter = "Reported_Date is null"
'Me.FilterOn = True

- This will apply the first filter, then the second, but then show the
Act_Complete records that has a value like it removed the first criteria.

I have tried this: 'Me.Filter = "Act_Complete = """ & Me.Reported_Date =
""" "

I just need to be able for it to exclude the records that have a date value
in either the Act_Complete or the Reported_Date field.

Please Help!


Thank you!
 
D

Dirk Goldgar

BMaerhofer said:
I have a form with a button to show only active records (without a closed
date or reported date). I need for it to show only the records that
Act_Complete is null and Reported_Date is null. I have tried many
different
types of VBA and had had no luck:

'Me.Filter = "Act_Complete is null"
'Me.FilterOn = True
'Me.Filter = "Reported_Date is null"
'Me.FilterOn = True

- This will apply the first filter, then the second, but then show the
Act_Complete records that has a value like it removed the first criteria.

I have tried this: 'Me.Filter = "Act_Complete = """ & Me.Reported_Date
=
""" "

I just need to be able for it to exclude the records that have a date
value
in either the Act_Complete or the Reported_Date field.


Me.Filter = "(Act_Complete Is Null) And (Reported_Date Is Null)"
Me.FilterOn = True
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top