View Single Post
  #1   Report Post  
Posted to microsoft.public.excel.programming
Jack Jack is offline
external usenet poster
 
Posts: 1
Default insert new row & fill down

Hi,

I'm trying to write a macro that allows users to insert a
new blank row anywhere on the spreadsheet AND fill down
the formulas from the above row.

For example,

Sheet 1 - an user wants to insert a blank row on line 50
and copy the formula from line 49 and the whole
spreadsheet shifts down one cell.

I've tried the record macro function and edit the script
but I get a run-error.

Here's the record macro script:

Sub testinsert()
Rows.EntireRow.Select
Selection.Insert Shift:=xlDown
Selection.FillDown
End Sub

I got a run-time error on line 2.

Thanks in advance.