Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Best approach to verify for exclusivity of a file
Message
De
08/08/2011 17:08:33
 
 
À
08/08/2011 16:33:06
John Baird
Coatesville, Pennsylvanie, États-Unis
Information générale
Forum:
ASP.NET
Catégorie:
Code, syntaxe and commandes
Versions des environnements
Environment:
VB 9.0
OS:
Windows 7
Network:
Windows 2003 Server
Database:
MS SQL Server
Application:
Web
Divers
Thread ID:
01520429
Message ID:
01520451
Vues:
56
>You can try to open the file for exclusive read :
>Stream stream = File.Open(myfileName, FileMode.Open, FileAccess.read, FileShare.None);
>if an error you'll receive an ioexception....

That's what I was looking for.

Thanks
Michel Fournier
Level Extreme Inc.
Designer, architect, owner of the Level Extreme Platform
Subscribe to the site at https://www.levelextreme.com/Home/DataEntry?Activator=55&NoStore=303
Subscription benefits https://www.levelextreme.com/Home/ViewPage?Activator=7&ID=52
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform