Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 2,202
Default Does VBA have a "continue" statement like C?

However, say, to avoid adding to an already large block of nested If's I
might use Goto to skip to the next section. Do you see anything
intrinsically wrong in that type of use of GoTo.


No, there is nothing intrinsically wrong with it at all... and many
programmers use it just the way you describe. However, there are also lots
of programmers, like me, who never use it at all. I have no trouble
constructing, or reading, a long block of nested If-Then-ElseIf blocks, so
that is what I prefer to do. To each his/her own. One note, however... if
things are getting lengthy in a nested If-Then-ElseIf block, placing the
active code in subroutines so that most levels are simply single line Call
statements helps to make things more readable.

Rick

Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
"Continue" and Exit with For Loops Andrew Hall NZ Excel Programming 4 November 23rd 06 02:44 AM
Change default in input box from "20" to "000000"? Have macro continue on to name sheet tab? StargateFanFromWork[_4_] Excel Programming 7 October 29th 06 11:46 AM
Deleted the pivot table - continue to get the "overlap" error message [email protected] Excel Discussion (Misc queries) 0 September 27th 06 04:07 PM
Automatically click "Update Links" & "Continue" paulharvey[_13_] Excel Programming 0 June 3rd 06 05:35 PM


All times are GMT +1. The time now is 09:57 AM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©2004-2025 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"