Nesting Autofilter functions

G

Guest

Is it possible to "Nest" autofilters? Reason for question is that I need to
autofilter my data log and search through all records (via Column "O") that
is equal to blank, but also through column E where criteria <= Ending date.

Example:

TextFilter1 = ActiveSheet.Range("E3:E10000").AutoFilter _
Field:=1, Criteria1:="<=" & EDate

ActiveSheet.Range("O3:O10000").AutoFilter _
Field:=1, Criteria1:="=", Operator:=xlAnd _
, Criteria2:="TestFilter1"
 
B

Bob Phillips

Try this

With ActiveSheet.Range("E3:O10000")
.AutoFilter Field:=1, Criteria1:="<=" & Format(Edate, "dd-mmm")
.AutoFilter Field:=11, Criteria1:="="
End With

note that you need to use a date format that the worksheet uses.

--

HTH

RP
(remove nothere from the email address if mailing direct)
 

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