Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Performance issues
Message
De
12/04/2004 11:06:21
 
 
À
Tous
Information générale
Forum:
Visual FoxPro
Catégorie:
COM/DCOM et OLE Automation
Titre:
Performance issues
Divers
Thread ID:
00894049
Message ID:
00894049
Vues:
48
This picks up on a question I asked earlier. Thanks to Cetin for answering. Your comments were very helpfull. Here's my second issue:

I instantiate Excel inside a VFP executable with this code:
oXL = CREATEOBJECT( "Excel.Application" )

I then parse through a VFP table and transfer the contents of that table into and excel spreadsheet created this way:
oWorkSheet = oXL.WorkBooks.Add( _myTemplate File_ )

The code to place the value into the spreadsheet, typically looks like this:
oWorkSheet.Sheets(1).Cells( nRow, nCol ).Value = nNewValue

This works just fine, with one "minor" issue: it is painfully slow. It takes 44 seconds on a 900mhz Duron powered machine to write and format a 500 row by 10 column set of data into the spreadsheet. I know VFP exports to Excel nearly instantaneously so I'm wondering if there isn't something that can be done to speed this up? I haven't used the "COPY TO _file_ TYPE XLS" approach because of some formatting requirements the client has imposed.
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform