Advertisement
If you have a new account but are having problems posting or verifying your account, please email us on hello@boards.ie for help. Thanks :)
Hello all! Please ensure that you are posting a new thread or question in the appropriate forum. The Feedback forum is overwhelmed with questions that are having to be moved elsewhere. If you need help to verify your account contact hello@boards.ie

Is there a break statement in VB?

Options
  • 28-03-2003 4:49pm
    #1
    Registered Users Posts: 1,722 ✭✭✭


    Is there any break statement in VB that if you execute will take you to the line directly after the last line of the loop? Like the break statement in C++?

    I was thinking of using GOTO but if I can't get away with not using that I rather not.


Comments

  • Registered Users Posts: 437 ✭✭Spunj


    do..while
    exit do

    for...next
    exit for

    that kinda thing?


  • Registered Users Posts: 1,722 ✭✭✭Thorbar


    Great that's what I was looking for. Will that work if I put in inside an if statement which is within a loop?


  • Registered Users Posts: 15,443 ✭✭✭✭bonkey


    How hard can it be to code that and see ;) You coulda done that in the same length of time it took teh write the post :)

    Seriously though....it will work.....assuming what you want is "break if this statement is true" behaviour?

    jc


Advertisement