vba code to add X rows for each selected row
I devised the below vba code, (a modified version of the code posted here: https://trumpexcel.com/insert-blank-row-after-every-row/ ) to automatically enter X number of rows after each selected row on a worksheet.
Change the number at the end of
to set the number of rows you want to insert, then increase the number after:
by one more number than the number of rows you want to add.
'This code will insert a row after every row in the selection
'This code has been created by Sumit Bansal from trumpexcel.com
Dim rng As Range
Dim CountRow As Integer
Dim i As Integer
Set rng = Selection
CountRow = rng.EntireRow.Count
For i = 1 To CountRow