>I agree entirely. I consider EXIT and LOOP to be bugs until proven otherwise :-) Almost without exception, it's an indication that the coder hasn't thought the logic through clearly, making the entire structure suspect.
I consider them the VFP equivalent of < shudder > GOTO...:-)
>Personally, I also consider an IF statement without an ELSE in the same class.
Sometimes, I think that this is ok consider:
FUNCTION SomeFunc
LOCAL lnresult
lnresult = 0
IF < Some logical expression >
lnresult = 99
ENDIF
RETURN lnresult
ENDFUNC
I tend to initialize my return variables almost immediately. Add ing an ELSE here might be overkill. Normally, most of my methods are around 20 lines so it's easy to see what's going on.
George
Ubi caritas et amor, deus ibi est