3

This code works as intended but I also need to exclude Autoreplies and some other strings in a subject line. I need to know if it's possible to add 2 or 3 more Likes.

I tried And and Or conditions but I'm getting a parse error.

This code below works. I just need to add another string condition after undeliverable. " Like '%Automatic reply%'".

Filter = "@SQL=" & " Not " & _
             "urn:schemas:httpmail:subject" & "" & _
             " Like '%undeliverable%'"

thanks.

Martijn Pieters
  • 1,048,767
  • 296
  • 4,058
  • 3,343
wh3resmycar2
  • 191
  • 1
  • 13

1 Answers1

4

OR Should work, The following Example have either %undeliverable% Or %Automatic reply%


Filter = "@SQL=" & " Not (urn:schemas:httpmail:subject" & _
                   " Like '%undeliverable%'  Or " & _
                         "urn:schemas:httpmail:subject" & _
                   " Like '%Automatic reply%')"

To Add one more Filter

Filter = "@SQL=" & " Not (urn:schemas:httpmail:subject" & _
                   " Like '%undeliverable%'  Or " & _
                         "urn:schemas:httpmail:subject" & _
                   " Like '%Automatic reply%' Or " & _
                         "urn:schemas:httpmail:subject" & _
                   " Like '%Bla Bla%')"
0m3r
  • 12,286
  • 15
  • 35
  • 71