Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Single exit-point
Message
From
03/04/2002 10:18:40
Hilmar Zonneveld
Independent Consultant
Cochabamba, Bolivia
 
General information
Forum:
Visual FoxPro
Category:
Coding, syntax & commands
Miscellaneous
Thread ID:
00640316
Message ID:
00640351
Views:
19
Thanks; I find this an interesting alternative, but in many cases (it seems to me) the steps can NOT be coded into a single expression that returns .T. or .F. For instance, I do a SELECT - SQL, and want to check that exactly one record was found (_tally = 0).

Hilmar.

>Hilmar,
>
>if you have to process more than one or two lines of code in each step, this might be an (ok, a little unusual) option. As long as your single step functions return .T., the next function is run. If all functions return .T., OTHERWISE is the last step.
>
>
>DO CASE
>   CASE NOT DoFirstStep()
>      llSuccess = .F.
>   CASE NOT DoSecondStep()
>      llSuccess = .F.
>   CASE NOT DoThirdStep()
>      llSuccess = .F.
>   OTHERWISE
>      llSuccess = .T.
>ENDCASE
>
>*-- Clean up
>
>RETURN llSuccess
>
>
>Armin
Difference in opinions hath cost many millions of lives: for instance, whether flesh be bread, or bread be flesh; whether whistling be a vice or a virtue; whether it be better to kiss a post, or throw it into the fire... (from Gulliver's Travels)
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform