• 游啊游
  • 信仰
  • 原点
  • 清明
  • 关不上的窗
  • 雨一直下-古筝
  • 你的样子
  • Sofía
  • Suddenly
  • Traveling Light
  • 城南花已开
  • 简单与秋夜
  • 最美的期待
Oo笑容太甜oO/

Excel宏合并多列(处理面板数据)


Sub 多列合并()
Dim i As Integer, j As Integer, n As Integer
n = 0
For j = 2 To 200 Step 1
   If Cells(1, j) = "" And Cells(1, j + 1) = "" Then Exit For
   For i = 1 To 100 Step 1
      If Cells(i, j) = "" Then Exit For
      n = n + 1
      Cells(n, 1) = Cells(i, j)
   Next i
Next j
End Sub

暂无评论