Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
How to make this code faster
Message
De
02/05/2013 12:42:14
 
 
À
02/05/2013 12:29:34
Mk Sharma
Shrishti Solutions
Mumbai, Inde
Information générale
Forum:
Visual FoxPro
Catégorie:
Base de données, Tables, Vues, Index et syntaxe SQL
Versions des environnements
Visual FoxPro:
VFP 9 SP2
OS:
Windows 7
Network:
Windows XP
Database:
Visual FoxPro
Application:
Desktop
Divers
Thread ID:
01572484
Message ID:
01572503
Vues:
48
No need to GO TOP as the record pointer will already be positioned there, but the time to run that line of code is so small that it won't be noticed.

You can run the code with the Coverage Profiler. It will tell you what lines are slowest and give you ideas where optimization should be done.


>USEFILE() is to use and select the dbf file.
>
>
>** usefile.prg
>Lparameter m.FILENAME, m.AFILENAME
>If Empty(m.AFILENAME)
>	AFILENAME = m.FILENAME
>Endif
>Local FILENAME2
>FILENAME2 = Alltrim(OAPP.ZDATAPATH) + m.FILENAME
>If Not Used(m.AFILENAME)
>	Use (m.FILENAME2) Again In 0 Alias (m.AFILENAME) Shared
>	Select (m.AFILENAME)
>	Go Top
>Endif
>Select (m.AFILENAME)
>
Craig Berntson
MCSD, Microsoft .Net MVP, Grape City Community Influencer
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform