Thread
:
Macro repeat
View Single Post
#
2
Posted to microsoft.public.excel.worksheet.functions
Don Guillett
external usenet poster
Posts: 10,124
Macro repeat
Not exaclty sure what you want but test this to see if if helps.
Sub doovereach10()
lr = Cells(Rows.Count, "k").End(xlUp).Row
For i = 1 To lr Step 10
For j = 1 To 10
Cells(i, "k").Offset(j) = i
Next j
Next i
End Sub
--
Don Guillett
Microsoft MVP Excel
SalesAid Software
"decimal" wrote in message
...
How do you make a macro repeat over and over until you tell it to stop.
In
lotus you could make it loop back on itself until you hit ctrl somehting
to
interupt it. I have 3000 lines in groups of 10, doing something to each
of
the 10, then the same thing to the next 10. Since a macro always starts
in
its original cell(a bug?), I need to just keep moving down, like I had it
learn to move down 10 times. In this case I would have it move the 11th,
and
repeat itself. I don't know how to do that...
-Decimal
Reply With Quote
Don Guillett
View Public Profile
Find all posts by Don Guillett