How To Insert Multiple Blank Rows in Excel

Creating a macro in Microsoft Excel offers users the ability to automate repetitive and predictable tasks in the program, often saving hours of time.

Insert Blank Rows Between Data Entries

If you would like to create a macro that will insert 2 blank rows into an existing spreadsheet after every 2 data entries, there is an available macro that can help you do so. The end result should look like this:

Default layout:

After Macro:


Inserting Multiple Blank Rows Between Existing Data

Utilizing the following macro will get you the result pictured above:
Sub test()
Dim j As Long, r As Range
j = InputBox("type the number of rows to be insered")

Set r = Range("A2")
Range(r.Offset(1, 0), r.Offset(j, 0)).EntireRow.Insert
Set r = Cells(r.Row + j + 1, 1)
'MsgBox r.Address(the apostrophe in the beginning of this line makes this line non operable)
If r.Offset(1, 0) = "" Then Exit Do

End Sub
Published by aakai1056. Latest update on September 30, 2015 at 03:19 PM by ChristinaCCM.
This document, titled "How To Insert Multiple Blank Rows in Excel," is available under the Creative Commons license. Any copy, reuse, or modification of the content should be sufficiently credited to CCM (
Excel - A Macro to display comment on mouse-over
Excel - Compare data from two columns