Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
How much faster or slower is to use with..endwith?
Message
Information générale
Forum:
Visual FoxPro
Catégorie:
Programmation Orientée Object
Divers
Thread ID:
00407175
Message ID:
00407575
Vues:
24
Goes to show I'm lucky sometimes - I went back to my most recent Word automation which I'd done with WITH/ENDWITH, did a quick search/replace to remove all of the With/Endwith constructs and re-ran the document. You're right - the time elapsed over several runs was significantly higher. Glad I did it right before distributing it, but now I'll know WHY to do it this way in the future.

Thanks,
Barbara

>When working with VFP innate objects and custom objects created with VFP constructs the difference in access time can be minimal.
>
>But try this same technique when there is a COM barrier between you and the other object (e.g. Word, Excel, custom VFP COM server) and you see the benefits of With/Endwith very quickly. It can shave seconds off processing time instead of milliseconds. It is for this reason I use With/Endwith almost exclusively. The only time I don't is when I have 1 PEM to access.
>
>Just my $0.02.
Barbara Paltiel, Paltiel Inc.
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform