Restarting a macro
Maybe you could just loop between column 1 and the maximum column:
dim cCtr as long
for cctr = 1 to activesheet.columns.count
'do something
next cctr
Say you want to loop through rows looking through columns:
dim cCtr as long
dim rCtr as long
for rctr = 1 to 10
for cctr = 1 to activesheet.columns.count
msgbox activesheet.cells(rctr,cctr).value
next cctr
next rctr
=====
If this doesn't help (and I'd be kind of surprised if it did!), you may want to
add some more detail to your question.
BR wrote:
I have a macro that loops from column A to column IV(the last column in
Excel). Once the last column is read how can I cause my macro to restart at
the column A again? Can I set my macro to return to column A after it reads
column IV. What would be the macro syntax for that? Thanks.
--
Dave Peterson
|