Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1
Default Advanced Filter

How with code would I do an auto filer - unique values and
copy these values to another sheet?

thanks
  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 41
Default Advanced Filter


Sheets("Sheet1").Range("A1:A10").AdvancedFilter Action:=xlFilterCopy, _
CopyToRange:=Sheets("Sheet2").Range("A1"), Unique:=True

Regards
Pascal

"Mister Dolopo" a écrit dans le message de
...
How with code would I do an auto filer - unique values and
copy these values to another sheet?

thanks



  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 11,123
Default Advanced Filter

Try this Mister

Column A must have a header cell

Sub test()
ActiveSheet.Columns("A:A").AdvancedFilter _
Action:=xlFilterCopy, _
CopyToRange:=Sheets("Sheet2").Range("A1"), Unique:=True
End Sub



--
Regards Ron de Bruin
(Win XP Pro SP-1 XL2000-2003)
www.rondebruin.nl



"Mister Dolopo" wrote in message ...
How with code would I do an auto filer - unique values and
copy these values to another sheet?

thanks



  #4   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1
Default Advanced Filter

Thanks Guys,

Small problem, this macro copies my heading value as well
as the data below. Can this be rectified to only copy the
data?

thanks


-----Original Message-----
Try this Mister

Column A must have a header cell

Sub test()
ActiveSheet.Columns("A:A").AdvancedFilter _
Action:=xlFilterCopy, _
CopyToRange:=Sheets("Sheet2").Range("A1"),

Unique:=True
End Sub



--
Regards Ron de Bruin
(Win XP Pro SP-1 XL2000-2003)
www.rondebruin.nl



"Mister Dolopo" wrote in message

...
How with code would I do an auto filer - unique values

and
copy these values to another sheet?

thanks



.

  #5   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 2,824
Default Advanced Filter

Just delete the cell (and shift up) or delete the whole row after you do the
copy.

....
sheets("sheet2").rows(1).delete
....



Mister Dolopo wrote:

Thanks Guys,

Small problem, this macro copies my heading value as well
as the data below. Can this be rectified to only copy the
data?

thanks

-----Original Message-----
Try this Mister

Column A must have a header cell

Sub test()
ActiveSheet.Columns("A:A").AdvancedFilter _
Action:=xlFilterCopy, _
CopyToRange:=Sheets("Sheet2").Range("A1"),

Unique:=True
End Sub



--
Regards Ron de Bruin
(Win XP Pro SP-1 XL2000-2003)
www.rondebruin.nl



"Mister Dolopo" wrote in message

...
How with code would I do an auto filer - unique values

and
copy these values to another sheet?

thanks



.


--

Dave Peterson



Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Advanced Filter - filter rows < jaws4518 Excel Discussion (Misc queries) 3 November 1st 06 05:48 PM
Why won't advanced filter return filter results? jaws4518 Excel Worksheet Functions 5 September 12th 06 06:11 PM
How do I use advanced filter to filter for blank cells? Monique Excel Discussion (Misc queries) 2 March 21st 06 06:43 PM
"Criteria Range" in the "Data/Filter/Advanced Filter" to select Du TC Excel Worksheet Functions 1 May 12th 05 02:06 AM
advanced filter won't allow me to filter on bracketed text (-456.2 LucianoG Excel Discussion (Misc queries) 1 December 6th 04 08:38 PM


All times are GMT +1. The time now is 10:32 AM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©2004-2025 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"