Since you insist...
>FOR T=1 TO 10
>    FOR Q=1 TO 6
>        FOR X=1 TO 9
>             IF CONDITION THEN EXIT ; EXIT
>                            OR
>             IF CONDITION THEN CONTINUE T
>        NEXT X
>    NEXT Q
>NEXT T

FOR T=1 TO 10 until abort.flag > 0
    FOR Q=1 TO 6 until abort.flag > 0
        FOR X=1 TO 9
             IF CONDITION THEN abort.flag = 1; EXIT
                            OR
             IF CONDITION THEN CONTINUE
        NEXT X
    NEXT Q
NEXT T

I place the inside FOR..NEXTS at the lowest point possible in the outer
loops, so that an end to an inner loop will result in a flag check in
the outer loop, resulting in a clean exit.

If the process is a bit more exotic I set the abort.flag to various
numbers, with the test for "abort.flag" evaluating to true whatever the
number, and my being able to determine what the problem was at the end,
and by not changing the counter variables (eg to 10 or 6) one can know
exactly which loop of what loop.

perfect debugging

---------------------------------------------------------
GWK BEPERK/LIMITED (REG: 1997/022252/06)
POSBUS 47 PO BOX 8730
DOUGLAS

Direkteure/Directors: NB Jacobs, FJ Lawrence, J v/d S Botes,
JH Coetzee, JGD Smit, JF Jacobs, AO M|ller, JW Smit,
WG M|lke, JG Stander, JH van Dyk(MD/BD), JG Jacobs, A M|ller, M van Zyl,
Sekr/Secr: E van Niekerk.

Hierdie e-pos is onderworpe aan 'n vrywaring beskikbaar by:
http://www.gwk.co.za/DisclaimerVrywaring.asp
This e-mail is subjected to the disclaimer that can be viewed at:
http://www.gwk.co.za/DisclaimerVrywaring.asp
-------
u2-users mailing list
[email protected]
To unsubscribe please visit http://listserver.u2ug.org/

Reply via email to