快好知 kuaihz

电脑技巧达人vba基础篇

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

本站资源来自互联网,仅供学习,如有侵权,请通知删除,敬请谅解!
搜索建议:电脑技巧达人vba基础篇  达人  达人词条  电脑技巧  电脑技巧词条  基础  基础词条  vba  vba词条