用VBA速度快多了: Sub gvntw() Dim i As Long Dim c As Range Dim rg As Range Dim tmp As String Dim Class As New Collection Application.ScreenUpdating = False For Each c In Range("A1:A" & Range("A65536").End(xlUp).Row) tmp = tmp & c.Value Next tmp = Replace(tmp, ",", "") Range("B:S").ClearContents On Error Resume Next For i = 1 To Len(tmp) Class.Add Mid(tmp, i, 1), Mid(tmp, i, 1) Next On Error GoTo 0 Set rg = Range("B2") For i = 1 To Class.Count rg = Class(i) Set rg = IIf(rg.Column = 19, Cells(rg.Row + 1, 2), rg.Offset(, 1)) Next Application.ScreenUpdating = True End Sub
m8VEhVj4.rar
(11.53 KB, 下载次数: 13)
|