use of an "OR" "AND" with a filter statment

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

Guest

I am trying to set a filter in my code after a button is selected. I can get
it to work with:

Me.Filter = "Imp_Status<>'Done'"
Me.FilterOn = True

However I really want it filter out all of the 'Done' and 'Disaproved'
values in the Imp_Status field. Ther are six different posible selections in
this field and the other 4 make reference to work still in progress. Can
someone please help me figure out how to do this please.

Beards
 
Try replacing your first line with:
Me.Filter = "(Imp_Status <> 'Done') AND (Imp_Status 'Disaproved' <>)"

My personal preference where this is more than one value would be:
Me.Filter = "Imp_Status Not In ('Done', 'Disaproved')"
 
Hi,

Have you tried

Me.Filter = "(Imp_Status<>'Done') And (Imp_Status<>'Disaproved')"

Sam
 
Back
Top