Tuesday, November 8, 2016

Excel Copy Unique Values To Other Sheet

Excel Vba Copy Unique Values

           Unique values are found with macro.
The unique values in column A are listed in column A of the other page. Template's codes:

"Sub Unlikecopy()
With Sheets("Sheet1")
    .Range("A1:A" & .Cells(Rows.Count, 1).End(xlUp).Row).AdvancedFilter Action:=xlFilterInPlace, Unique:=True
    .Range("A1:A" & .Cells(Rows.Count, 1).End(xlUp).Row).Copy Sheets("Sheet2").Range("A1")
    .ShowAllData
End With
End Sub"


excel vba copy unique values