Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Is A File Aready Open?
Message
De
13/10/2002 16:36:11
 
 
À
13/10/2002 15:21:33
Information générale
Forum:
Visual FoxPro
Catégorie:
Fonctions Windows API
Divers
Thread ID:
00710752
Message ID:
00710761
Vues:
26
This message has been marked as a message which has helped to the initial question of the thread.
>Hi:
>
>I write to an RTF file that could be open in Word on the same workstation.
>
>Is there any way of testing whether the file is actually open, as far as Windows is concerned? If I knew the file was currently open, I could prevent the "write to" operation from within VFP until the file is closed by whatever application has it open.
>

Try to FOPEN() the file exclusively; if it fails, the file is already open.

>Thanks!
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
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform