返回列表 上一主題 發帖

點選複製

  1. Sub 多重分析()
  2.     Dim Rng As Range, A As Range
  3.     With Sheet1
  4.         Set Rng = .Range("I2").CurrentRegion
  5.         r = Selection.Count
  6.         If Not Intersect(Selection, Rng) Is Nothing Then
  7.         Set A = .Range("A" & Rows.Count).End(xlUp).Offset(1, 0)
  8.             Application.Intersect(Selection.EntireRow, Rng).Copy A.Offset(, 8)
  9.             .[A2].Copy A
  10.             A.AutoFill A.Resize(r, 1)
  11.        End If
  12.     End With
  13. End Sub
複製代碼
學海無涯_不恥下問

TOP

回復 6# myleoyes


    If R>1 then A.AutoFill A.Resize(R, 1)
學海無涯_不恥下問

TOP

        靜思自在 : 君子立恆志,小人恆立志。
返回列表 上一主題