Selecting Filtered Items from Named range

S

Soniya

Hi all,

I have the following:
Column D data area is defined as "My List"
No I filter the sheet Field 4 (Mylist) and returns the
data based on crieteria
how can I select only those filtered items less Label to
copy to other column??

TIA
Soniya
 
B

Bob Phillips

Somiya,

Use SpecialCells with the visble cells qualifier

Range("myList").SpecialCells(xlCellTypeVisible).Copy
Destination:=Range("M1")


Change M1 to suit
 
K

keepitcool

Soniya,

if cells below list are blank anyway
shift down 1 row before specialcells method

Range("myList").Offset(1). _
SpecialCells(xlCellTypeVisible).Copy _
Destination:=Range("M1")

else you'll have to both offset and resize

Range("myList").Offset(1). _
Resize(Range("MyList").Rows.Count - 1). _
SpecialCells(xlCellTypeVisible).Copy _
Destination:=Range("M1")


keepITcool

< email : keepitcool chello nl (with @ and .) >
< homepage: http://members.chello.nl/keepitcool >
 

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