Attachment is too large to upload. Here are codes. 运行时间:1.140625 测试时间:69.5625
Private Sub CommandButton1_Click() t = Timer Dim ds As Object, i As Long, arr, s As String i = Me.Range("a65536").End(xlUp).Row arr = Me.Range("a1:a" & i) arr = Application.Transpose(arr) s = Join(arr, ",") arr = Split(s, ",") Set ds = CreateObject("scripting.dictionary") On Error Resume Next For i = LBound(arr) To UBound(arr) ds.Add arr(i), i Next i On Error GoTo 0 arr = ds.keys arr = Application.Transpose(arr) Me.Range("b1:b" & UBound(arr)) = arr Range("g1") = Timer - t End Sub
[此贴子已经被山菊花于2006-6-29 19:49:32编辑过] |