![]() |
![]() |
|
|||||||
| Excel Questions All Excel/VBA questions - formulas, macros, pivot tables, general help, etc. Please post to this forum in English only. |
|
|
Thread Tools | Display Modes |
|
|
#1 |
|
Join Date: Mar 2004
Location: Dubai
Posts: 338
|
Dear Experts,
I am trying to remove duplicates from Column C. The Range is from C11 - C55. I have the following code, which seems to work perfect when the data starts from A1…. Could you please amend this code or give another code so that my purpose may get fulfilled. Private Sub CommandButton1_Click() 'Add extra Column, "A" becomes "B" Columns(1).EntireColumn.Insert 'Filter out duplicates and copy unique list to "A" Range("B1", Range("B65536").End(xlUp)).AdvancedFilter _ Action:=xlFilterCopy, CopyToRange:=Range("A1"), Unique:=True 'Add extra Column, "B" becomes "A" Columns(2).EntireColumn.Delete End Sub Regards Shan |
|
|
|
| Bookmarks |
| Thread Tools | |
| Display Modes | |
|
|