View Single Post
  #4   Report Post  
Posted to microsoft.public.excel.programming
Carrie_Loos via OfficeKB.com Carrie_Loos via OfficeKB.com is offline
external usenet poster
 
Posts: 116
Default Stop the macro at the end of a certain column

Thanks - still not quite there yet.

What I ended up doing is putting the statement after the "find" portion for a
1 and placing a 1 in cell AU65535. When I step through the macro it does run
correctly and end up on cell AU65535 but it does not recoginze the c.Address
and skips to the End if.

In leiu of c.Address I have also tried ActiveCell and/or range TopCell with
no luck, I even changed the orginal set range to end at AU65534. Is there any
other way to identify the cell so that the macro exits or stops?

JLGWhiz wrote:
???????Stop at the end of column AU???????

Put this in where the above line appears:

If c.Address = "AU65535" Then
Exit For
End If

Can anyone tell me how to write the string of code to stop a macro at a
certain point? I have the following macro that runs through a range but

[quoted text clipped - 40 lines]

End Sub


--
Message posted via http://www.officekb.com