|
参与一下。。。- Sub ykcbf() '//2024.1.12
- Set d = CreateObject("Scripting.Dictionary")
- Set sh = ThisWorkbook.Sheets("查询结果")
- For Each sht In Sheets
- If sht.Name <> sh.Name Then
- If sht.UsedRange.Count > 10 Then
- arr = sht.UsedRange
- For i = 2 To UBound(arr)
- s = arr(i, 2)
- If Not d.exists(s) Then
- d(s) = Array(s, arr(i, 3))
- End If
- Next
- End If
- End If
- Next
- With sh
- .[b2:c10000] = ""
- .Columns(2).NumberFormatLocal = "@"
- .[b2].Resize(d.Count, 2) = Application.Rept(d.Items, 1)
- End With
- Set d = Nothing
- MsgBox "OK!"
- End Sub
复制代码
|
评分
-
1
查看全部评分
-
|