Add row and text between each row
Give this a try...
Sub InsertLines()
Dim wks As Worksheet
Dim rng As Range
Set wks = ActiveSheet
With wks
Set rng = .Cells(Rows.Count, "A").End(xlUp)
Do While rng.Row 1
rng.EntireRow.Insert
rng.Offset(-1, 0).Value = "'========="
Set rng = rng.Offset(-2, 0)
Loop
End With
End Sub
--
HTH...
Jim Thomlinson
"JR" wrote:
I have an excel spreadsheet with 20k rows of data. Want to add a row
in between each one and in column A of each newly created row put in
"=========" without the quotes. Can someone suggest a macro to do
this?
Thanks.
JR
|