Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Invalid File Descriptor, file is already open by excel.
Message
From
26/01/2000 14:28:02
 
 
To
26/01/2000 13:04:52
Paul De Niverville
Deniverville Econometric Research Ltd.
Victoria, British Columbia, Canada
General information
Forum:
Visual FoxPro
Category:
Other
Miscellaneous
Thread ID:
00322977
Message ID:
00323034
Views:
28
>Hi,
>
>I have a program that copies a table to excel format. Sometimes the client has a previous version of the spreadsheet open and VFP cannot create a new file of the same name. At this point I get the error 1111 Invalid File Descriptor.
>
>There is probably a way of determining if a file is open by another application, before trying to create a new one of the same name.
>

If you know you're going to blow away the old copy entirely IAC, what about using FCREATE() to open it low-level - if it works, FCLOSE() it and it's gone, and make your copy. IF FCREATE() fails, send the Corsican Brothers over to kick the user out, and repeat until it works.
EMail: EdR@edrauh.com
"See, the sun is going down..."
"No, the horizon is moving up!"
- Firesign Theater


NT and Win2K FAQ .. cWashington WSH/ADSI/WMI site
MS WSH site ........... WSH FAQ Site
Wrox Press .............. Win32 Scripting Journal
eSolutions Services, LLC

The Surgeon General has determined that prolonged exposure to the Windows Script Host may be addictive to laboratory mice and codemonkeys
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform