I would like to autofilter with 5+ criteria, but my code falls over if I try more than 2.
is there a work around or alternative method without stepping through each line?
Works
Doesn't Work
is there a work around or alternative method without stepping through each line?
Works
Code:
Sheets("data").Range("A:P").AutoFilter Field:=1, Criteria1:="<>R2*" _
, Operator:=xlAnd, Criteria2:="<>T2*"
Doesn't Work
Code:
Sheets("data").Range("A:P").AutoFilter Field:=1, Criteria1:="<>R2*" _
, Operator:=xlAnd, Criteria2:="<>T2*" _
, Operator:=xlAnd, Criteria3:="<>N2*" _
, Operator:=xlAnd, Criteria4:="<>B2*" _
, Operator:=xlAnd, Criteria5:="<>DEV*"