|
|
[广告] Excel易用宝 - 提升Excel的操作效率 · Excel / WPS表格插件 ★ 免费下载 ★ ★ 使用帮助★
本帖最后由 ykcbf1100 于 2025-12-19 17:49 编辑
- Sub ykcbf() '//2025.12.19
- Set d = CreateObject("Scripting.Dictionary")
- arr = Sheets("工资汇总").UsedRange.Value
- For i = 3 To UBound(arr)
- d(arr(i, 2) & " " & arr(i, 3)) = d(arr(i, 2) & " " & arr(i, 3)) + 1
- Next
- With Sheets("各园报表")
- r = .Cells(.Rows.Count, "ax").End(xlUp).Row
- For i = 6 To r
- s = .Cells(i, 50).Value & " " & .Cells(5, 51).Value
- If d(s) <> "" Then .Cells(i, 51).Value = d(s)
- Next
- End With
- End Sub
复制代码
|
|