Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.programming
|
|||
|
|||
AutoFilter Confusion (no records found)
I am having soem problems figuring out how to tackle a problem. I have been
successful in [1] autofiltering a spreadsheet; [2] selecting the filtered data and [3] copying it to a new sheet where I further manipulate it. However, I have found that when my autofilter finds no appropriate data (no record between two dates) instead of getting zero records I instead get all of the data copied. Can someone shed light on this and point me in the proper direction? Here is part of my selection and copy process: dLrow = Cells(Rows.Count, "P").End(xlUp).Row 'Field:=16 is Column P(card expiration date), D(last name, C(first name) Selection.AutoFilter Field:=16, Criteria1:="=" & startFilter, Operator:=xlAnd _ , Criteria2:="<" & endFilter Range("D3:D" & dLrow & ",E3:E" & dLrow & ",P3:P" & dLrow).Select Selection.Copy Workbooks.Add Range("A2").Select ActiveSheet.Paste |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
In Excel, How do I get AutoFilter to provide# of records found? | Excel Discussion (Misc queries) | |||
AutoFilter - How to determine number of records found | Excel Programming | |||
Counter for records found during Find | Excel Programming | |||
How to "Capture" Records Found Number During AutoFilter | Excel Programming | |||
how do I display filtered records found | Excel Discussion (Misc queries) |