数据量大的话用sql吧
Sub cx()
Dim cnn As New ADODB.Connection
Dim rds As New ADODB.Recordset
Dim i As Integer
Dim sql As String, sfilename As String, cnnstr As String
sfilename = ThisWorkbook.FullName
cnnstr = "Provider=Microsoft.Jet.OLEDB.4.0;Extended Properties=Excel 8.0;Data Source=" & sfilename
sql = "select distinct * from [sheet1$] ;"
cnn.Open cnnstr
rds.Open sql, cnn, adOpenKeyset, adLockOptimistic
Sheets("sheet1").Range("b2").CopyFromRecordset rds
rds.Close: cnn.Close
Set rds = Nothing: Set cnn = Nothing
End Sub