ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Programming (https://www.excelbanter.com/excel-programming/)
-   -   two-condition loop (https://www.excelbanter.com/excel-programming/278918-two-condition-loop.html)

Jamie Martin[_2_]

two-condition loop
 
I am getting input from a user. After stage 1, he must verify what he has
entered. After stage 2, he must also verify what he's entered. However, if
either stage has errors, he needs to start again from the beginning. I
cannot do this (I tried):

Do
<instructions
Loop Until Condition1 = True
<instructions
Loop Until Condition2 = True

I could do what I want with a GoTo, but I understand that is poor practice
because it makes one's code unfollowable. Is there another structure I can
use that will be equivalent to the above?




All times are GMT +1. The time now is 08:32 AM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com