Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
EXCEL Office Automation-file won't close
Message
De
10/10/2009 17:23:24
Dragan Nedeljkovich
Now officially retired
Zrenjanin, Serbia
 
Information générale
Forum:
Visual FoxPro
Catégorie:
Autre
Versions des environnements
Visual FoxPro:
VFP 9 SP2
OS:
Vista
Database:
Visual FoxPro
Divers
Thread ID:
01428674
Message ID:
01428686
Vues:
54
>I am getting an OLE sharing violation error, although my EXCEL file is closed as demonstrated by the code below. The OLE Error occurs when using the APPEND FROM command in the bottom portion of the code. The specific error states: "OLE error code 0x80030020: A share violation has occurred."
>
>Is there some possibility that the oExcel.Quit command doesn't close the EXCEL file?

Maybe not immediately? Excel, just like any other sufficiently complicated app, creates temp files, creates a lock file etc - and has to clean up on exit. Perhaps it closes the sheet itself last, and the .quit() returns .t. immediately - while in the background the actual shutdown may take some time.

You may try some delay, perhaps. Or check whether fopen() of the .xls file triggers any errors, in a timed loop.

back to same old

the first online autobiography, unfinished by design
What, me reckless? I'm full of recks!
Balkans, eh? Count them.
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform