Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Why don't I see cleanup class?
Message
 
À
21/06/2002 11:58:42
Information générale
Forum:
Visual FoxPro
Catégorie:
Codage, syntaxe et commandes
Divers
Thread ID:
00671062
Message ID:
00671079
Vues:
15
Bill;

Old habits die hard! :) I do it both ways depending upon what I am doing. If I am working on someone elses code I use in line code and do not bother to spend time to rewrite the application. What ever works! :)

Tom


>Every time I see code written by someone else I always see things like:
>
>Procedure ??
>  lcTalk = Set('Talk')
>  Set Talk Off
>  .........
>  Set Talk &lcTalk
>EndProc
>
>Is there a reason people don't use a class to save & restore settings
>
>Procedure ??
>  loTalk = CreateObject('Save_Talk')
>  .....
>EndProc    && Local variables go out of scope forcing destroy()
>Define Class Save_Talk as Custom
>  cTalk = Set('Talk')
>  Procedure Init()
>    Set Talk off
>  EndProc
>  Procedure Destroy()
>    Set Talk This.&cTalk
>  EndProc
>EndDefine
>
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform