View Single Post
  #1   Report Post  
Posted to microsoft.public.excel.worksheet.functions
sunslight sunslight is offline
external usenet poster
 
Posts: 6
Default Macro needed for inserting blank rows

I need a macro to insert a set number of rows, scroll the mouse, hit the
hotkey again and rows are inserted there.

Specifically:

I want to put the cursor on a row and have two new rows (blank) inserted
beneath the row I have the mouse on.

Just scroll the mouse to a row, click a hotkey, two new rows are inserted,
scroll the mouse to a new location, hit the hotkey, two new rows inserted
there--and so forth.

I've tried; but my macro, every time I hit the hotkey, keeps adding row to
the initial location. It is using absolute address instead of relative & I
don't know how to get it to stop (if that's what needs to be done.)

The macro I made was --start it recording, choose a hotkey,
select a row beneath where I wanted the first new rows to appear,
select the row below that,
go to "Insert" on the toolbar
select row
stop Macro recording.

--no matter where I put the cursor, the news rows are added to the original
place that I selected the rows to go.

Bob