Lines Between rows

S

smck

I am working in Excel 2003 and need to insert lines sometimes one, two or 3
between rows with data. I am now doing it manually which is very tedious. Is
there a command or macro that can do this?

Thanks
 
J

Jacob Skaria

If you mean cell border; you can do that in one shot from menu
Format>Cells>Borders.

If this post helps click Yes
 
S

smck

Hi Jacob,
Thanks for your response. From your answer I realized I may not have
explained my request clearly. What I mean is inserting blank rows between the
rows of data, e.g.

123 456 678 875
345 823 230 985
123 832 910 330

needs to be:

123 456 678 875


345 823 230 985


123 832 910 330

Thanks
 
G

Gord Dibben

Sub InsertRows()
Application.ScreenUpdating = False
Dim NumRows As Integer
Dim r As Long
r = Cells(Rows.Count, "A").End(xlUp).Row
NumRows = InputBox("How many rows to insert?")
For r = r To 1 Step -1
ActiveSheet.Rows(r + 1).Resize(NumRows).Insert
Next r
Application.ScreenUpdating = True
End Sub


Gord Dibben MS Excel MVP
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top