inserting rows..!!

V

via135

hi

is there any macro to insert rows
between alternate rows in a selection..?

for example..i am selecting R1:R10
and i need blank rows between R1 & R3....R3 & R5....R5 & R7..so on..!

any hlp pl..?

-via135
 
J

Joel

Sub InsertRows()

MyRows = Selection.Rows.Count

For RowCount = (Selection.Row + MyRows - 1) To (Selection.Row + 1) Step -1

Rows(RowCount).Insert
Next RowCount


End Sub
 
V

via135

Sub InsertRows()

MyRows = Selection.Rows.Count

For RowCount = (Selection.Row + MyRows - 1) To (Selection.Row + 1) Step-1

   Rows(RowCount).Insert
Next RowCount

End Sub

thks..joel..!
it works like a charm..!
thks again!

-via135
 

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