Inserting blank rows

  • Thread starter Thread starter PL
  • Start date Start date
P

PL

Hi

I have 10 consecutive rows of data. I wish to insert a blank between each of
these 10 rows, is there a formula or method I can use to do this quickly? I
don't wish to manually insert the rows.

Thanks.
 
Try the below
--Suppose you have data in ColA and ColB. Use a helper column say Col C
--Enter 1 to 10 in C1:C10 and copy 1 to 10 to C11:C20
--Select the data in ColA to C. Sort Col C in ascending
--Delete Column C
 
H

In an unused column enter the numbers 1,3,5 down to last data row.
Below enter the numbers 2,4,6... representing empty rows to be inserted.

Select the entire table, and sort (Goto Data > Sort) on the column with
numbers just inserted.

Hopes this helps.
....
Per
 
This will work for any range selected

Option Explicit
Sub insertblankrowsinselection()
Dim fr As Long
Dim lr As Long
Dim i As Long

With Selection
Dim x As Long, y As Long
fr = .Rows(1).Row
lr = .Rows.Count + fr - 1
For i = lr To fr Step -1
Rows(i + 1).Insert
Next i
End With
End Sub
 
Back
Top