|
[广告] Excel易用宝 - 提升Excel的操作效率 · Excel / WPS表格插件 ★ 免费下载 ★ ★ 使用帮助★
参与一下。。。
- Sub ykcbf() '//2024.4.17
- arr = Sheets("原始1").UsedRange
- brr = Sheets("原始2").UsedRange
- ReDim crr(1 To UBound(arr), 1 To UBound(arr, 2) + UBound(brr, 2))
- For i = 1 To UBound(arr)
- m = m + 1
- n = 1
- crr(m, 1) = arr(i, 1)
- For j = 2 To UBound(arr, 2)
- n = n + 1
- crr(m, n) = arr(i, j)
- n = n + 1
- crr(m, n) = brr(i, j)
- Next
- Next
- With Sheets("修改后的原始1")
- .Cells.ClearContents
- .[a1].Resize(m, n) = crr
- End With
- MsgBox "OK!"
- End Sub
复制代码
|
评分
-
1
查看全部评分
-
|