I have an excel file that is about 7,000 lines.
I want to have a macro that auto creates two blank rows in between each of these lines.
The best VBA code I have come up with only puts 2 rows at the top of the file which is not helpful.
Any help is appreciated
Ex.
A B C D E F G
X Y Z A B C D
Sub Insert_Rows_Loop()
Dim CurrentSheet As Object
' Loop through all selected sheets.
For Each CurrentSheet In ActiveWindow.SelectedSheets
' Insert 2 rows at top of each sheet.
CurrentSheet.Range("a1:a2").EntireRow.Insert
Next CurrentSheet
End Sub
I want to have a macro that auto creates two blank rows in between each of these lines.
The best VBA code I have come up with only puts 2 rows at the top of the file which is not helpful.
Any help is appreciated
Ex.
A B C D E F G
X Y Z A B C D
Sub Insert_Rows_Loop()
Dim CurrentSheet As Object
' Loop through all selected sheets.
For Each CurrentSheet In ActiveWindow.SelectedSheets
' Insert 2 rows at top of each sheet.
CurrentSheet.Range("a1:a2").EntireRow.Insert
Next CurrentSheet
End Sub