View Single Post
  #1   Report Post  
Posted to microsoft.public.excel.programming
Leon Leon is offline
external usenet poster
 
Posts: 67
Default How to repeat a macro

I have a macro that looks like this:

ActiveCell.Offset(2, 0).Range("A1").Select
Selection.Cut Destination:=ActiveCell.Offset(-2, 1).Range("A1")
ActiveCell.Offset(2, 0).Range("A1").Select
Selection.Cut Destination:=ActiveCell.Offset(-4, 2).Range("A1")
ActiveCell.Offset(2, 0).Range("A1").Select
Selection.Cut Destination:=ActiveCell.Offset(-6, 3).Range("A1")
ActiveCell.Offset(-5, 0).Rows("1:8").EntireRow.Select
Selection.Delete Shift:=xlUp
ActiveCell.Offset(0, 2).Range("A1").Select

I'd like to have Excel repeat the macro for as many entries there are on the
spreadsheet (this macro being valid onl for one entry). Right now I do it
manually by pressing a shortcut for as long as it not done.

Any help will be gratefully appreciated.