Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Safe Table Opening Code -How's This?
Message
 
À
26/10/2001 11:47:19
Hilmar Zonneveld
Independent Consultant
Cochabamba, Bolivie
Information générale
Forum:
Visual FoxPro
Catégorie:
Base de données, Tables, Vues, Index et syntaxe SQL
Divers
Thread ID:
00573683
Message ID:
00573696
Vues:
20
They are going to be methods in a public-scope "data activity object" class that I am instantiating at app startup. So I'd call TOpen() instead of using VFP's use command. Everything is happening on the local box (no shared network access). I just wanted to be sure I got the table open properly (in case I already have it open elsewhere, etc).

What would you recommend in the Destroy() event to get every table tableupdate()'d etc?



>What sort of safety do you want?
>
>If you use an object instead, you can save yourself the trouble of closing the table in code: the table is closed in the class'es Destroy() event. As soon as the object variable gets out of scope, Destroy() fires!
>
>However, there is no need to close tables if you use the table in a form with a private DataEnvironment.
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform