|
参与一下。。。- Sub ykcbf() '//2024.8.8 修改保存
- Set d = CreateObject("Scripting.Dictionary")
- With Sheets("查询录入页")
- r = .Cells(Rows.Count, 2).End(3).Row
- c = .Cells(7, "XFD").End(1).Column
- zrr = .[b8].Resize(r - 7, c - 1)
- For i = 1 To UBound(zrr)
- s = zrr(i, 1) & "|" & zrr(i, 2)
- d(s) = i
- Next
- End With
- With Sheets("资料总表")
- r = .Cells(Rows.Count, 1).End(3).Row
- c = .Cells(4, "XFD").End(1).Column
- arr = .[a5].Resize(r - 4, c)
- For i = 1 To UBound(arr)
- s = arr(i, 1) & "|" & arr(i, 2)
- If d.exists(s) Then
- For j = 1 To UBound(arr, 2)
- arr(i, j) = arr(d(s), j)
- Next
- End If
- Next
- .[a5].Resize(r - 4, c) = arr
- End With
- MsgBox "OK!"
- End Sub
复制代码
|
评分
-
1
查看全部评分
-
|