define unique Advancefiltered range

S

Stefi

Hi All,

I made a unique filtering, it works:

Range("C2:C367").AdvancedFilter Action:=xlFilterInPlace, Unique:=True

How can I define a range consisting of the unique visible cells?

Thanks,
Stefi
 
M

Mike Fogleman

Here is an example using a smaller range than yours:

Sub Filtered_Range()
Range("C2:C45").AdvancedFilter Action:=xlFilterInPlace, Unique:=True
Range("C2:C45").SpecialCells(xlCellTypeVisible).Copy Range("D2")
ActiveSheet.ShowAllData
End Sub

Mike F
 

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

Similar Threads


Top