I would like a macro to insert 2 (or more) rows every 8th row.
Thanks.
B.
I would like a macro to insert 2 (or more) rows every 8th row.
Thanks.
B.
This is one way
Sub InsertRows()
'insert 2 rows after every exiting 8th row
Dim lEndRow As Long
Dim lInstRow As Long
lInstRow = 9
Do
lEndRow = Cells.Find(what:="*", searchorder:=xlByRows, _
searchdirection:=xlPrevious).Row
Rows(lInstRow).Resize(2, 256).Insert
lInstRow = lInstRow + 10
Loop Until lInstRow > lEndRow
End Sub
There are currently 1 users browsing this thread. (0 members and 1 guests)
Bookmarks