快生活 - 生活常识大全

电脑技巧达人基础篇


  Sub
  复制粘贴系列
  ()
  Dim LastRow As Long, a As Long
  Dim b As Integer, c As Integer
  d = Sheets.Count
  e = 1
  "
  表循环
  For b = 1 To s
  Sheets(b).Select
  "
  单元格查找
  For e = 1 To 100
  LastRow = ActiveSheet.UsedRange.Rows.Count
  "
  判断第五行复制
  If Cells(x, 1) = 5 Then
  Rows(x).Copy
  End If
  "
  判断第六行粘贴
  If Cells(x, 1) = 6 Then
  Rows(x).Paste
  End If
  Next
  Next
  End Sub
网站目录投稿:诗凡