Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Can't clear CAD / DTE classes
Message
De
23/06/2016 06:40:40
 
 
À
23/06/2016 02:53:18
Information générale
Forum:
Visual FoxPro
Catégorie:
Classes - VCX
Versions des environnements
Visual FoxPro:
VFP 9 SP2
OS:
Windows 7
Divers
Thread ID:
01637449
Message ID:
01637608
Vues:
76
Fernando,

understood.
private  ;
   , llvar2, llFlag ;
;
   , lcMsg, lcLbl, lcMenu;
;
   , lnCntx, lnOptions;
;

Store "" To;
    lcMsg, lcLbl, lcMenu;

Store 0 To;
  lnCntx, lnOptions;
was something necessary to switch to when faced with old code sporting 60+ privates in functions ;-)
Whenever one of the dinosaur codes crosses my way I switch back to this pattern, and for varinit of same type and more than 3 vars I employ it in new code as well - easy to read and easy to maintain. No, my count of variables is not regularly double - digit ;-))



>I've refered to LOCALs like this:
>
>
>LOCAL var1 ;
>   , var2 ;
>   , etc ;
>
>
>Having all vars in line, grouped or individual 1 by line is not the problem and anyone have it's preferences, but leaving the final ";" open in the last statement COULD BE a real problem, because if you, by mistake, write some code in the inmediate next line, then VFP will interpret that as a continuation on the last ";", generating all kind of "rare" problems that not allways are visible at first, and even can not generate a compilation error.
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform