Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Set Classlib at moment of use versus opening them all
Message
Information générale
Forum:
Visual FoxPro
Catégorie:
Classes - VCX
Divers
Thread ID:
00061040
Message ID:
00061298
Vues:
51
>I'm told that loading all the classlibs within an application is faster
>than issuing Set Classlib (whether additive or not) than issuing the
>command when you need it.
>
>main.prg
>set classlib to (all my libs) additive
>
>OR
>
>Some procedure or whatever
>
>set classlib to (the lib needed)
>.addobject() or createobject
>release classlib
>
>What's the better way? I need the fastest, but I've found that sometimes
>when using the first method (all opened), that one of two things happen;
>either it can't find the class definition which means the classlib was
>closed somewhere or something closed it (I'm quite positive that I've
>removed all release classlib commands), or it sometimes takes forever and a
>day to create the desired object which implies some sort of lengthy search
>by VFP to find it's definition.
>
>Because they sometimes seem to close for no apparent reason, I'm inclined
>to go back to issuing the command at the time of needing a specific object
>and then releasing it. But, I'm told that is the slowest manner in which
>to do so. So, all comments and suggestions are welcome. I'd like to know
>how others are doing it.
>
>Steve Despres
>[ and GMRIDER added: ] So far, in my world, I open all libraries and such at the beginning of my applications. I've always looked at it as a convenience and performance thing - convenience for me (they are always open and available) and on the performance issue, I would rather take the performance hit at the beginning of the application. You know, takes forever to startup but once it is running, it runs like a bat out of hell...
>
>Looking forward to hearing what others do and why!

Cool signature!

:0)
If we exchange an apple, we both get an apple.
But if we exchange an idea, we both get 2 ideas, cool...


Gérald Santerre
Independant programmer - internet or intranet stuff - always looking for contracts big or small :)
http://www.siteintranet.qc.ca
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform