Bom dia!!
Os dados podem ser removidos da Plan2, depois posto o resultado?
Caso sim, teste esse.
Sub AleVBA_26332()
'Copia duplicados para outra guia, depois [remove duplicidades].
With Sheets("Plan2")
.Columns("H").ClearContents '<<- limpa a coluna H da Plan2
Sheets("Plan1").Columns("H").AdvancedFilter Action:=xlFilterCopy, CopyToRange:=.Range("H2"), Unique:=True
.Range("H1", .Range("H" & .Rows.Count).End(xlUp)).SpecialCells(xlBlanks).Delete Shift:=xlUp
End With
End Sub
Outra opção seria...
Sub AleVBA_26332V2()
Dim i As Variant
Dim j As Variant
j = Application.Transpose(Range("H2", Range("H" & Rows.Count).End(xlUp)))
With CreateObject("Scripting.Dictionary")
For Each i In j
.Item(i) = i
Next i
Sheets("Plan2").Range("H2:H" & Sheets("Plan1").Cells(Rows.Count, "H").End(xlUp).Row).ClearContents
Sheets("Plan2").Range("H2").Resize(.Count) = Application.Transpose(.Keys)
End With
End Sub
Att
Existem mil maneiras de preparar Neston. Invente a sua!
http://www.youtube.com/ExpressoExcel
Postado : 20/10/2017 7:41 am