Thread
:
short circuit for next; continue?
View Single Post
#
6
Posted to microsoft.public.excel.programming
Don Guillett[_2_]
external usenet poster
Posts: 1,522
short circuit for next; continue?
If I understand
y=12
for i = 2 to y
if lcase(cells(i,"b"))="yes" then
msgbox cells(i,"c")
exit for
else
msgbox "go on"
end if
next i
--
Don Guillett
Microsoft MVP Excel
SalesAid Software
"cate" wrote in message
...
Is there a way to do this in vba? (I can do this with structure but I
want to know if there is a perl/C# analog to (continue")
for x = 2 to y
answer = sub_testing()
if answer = 1
continue ' skip the reset of loop code and go back and get the
next value. No point in going on
end if
do more stuff
do more stuff
next
thank you.
Reply With Quote
Don Guillett[_2_]
View Public Profile
Find all posts by Don Guillett[_2_]