Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
If structure
Message
De
17/06/2008 12:32:44
 
Information générale
Forum:
Visual FoxPro
Catégorie:
Codage, syntaxe et commandes
Titre:
Versions des environnements
Visual FoxPro:
VFP 9 SP2
Divers
Thread ID:
01324796
Message ID:
01324807
Vues:
11
>Since Dbase III I don't need to use IF as below
>I've been using do case and IF with different structures
>
>Now I had to use it and, for my surprise, it does not work in VFP
>
>(endif missing)
>
>Moises
>
>
>
>
>IF CONFIG2.N5 = 1
> THISFORM.PRINT1
> ELSE
> IF CONFIG2.N5 = 2
> THISFORM.PRINT2
> ENDIF


I really prefer CASE structure for such cases:
DO CASE
     CASE CONFIG2.N5 = 1
               THISFORM.PRINT1
     CASE CONFIG2.N5 = 2
               THISFORM.PRINT2
ENDCASE
Against Stupidity the Gods themselves Contend in Vain - Johann Christoph Friedrich von Schiller
The only thing normal about database guys is their tables.
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform