### How do I lock a file? ###

  • Thread starter Thread starter BuzzLight
  • Start date Start date
B

BuzzLight

Hello, I would like my program to somehow lock a file on the file system ... say c:\myfile.mdb... so when the program is running the file is un-moveable, but NOT un-editable, This is to prevent users from moving the file during program execution.. which would lead to alot of errors in the program if it were allowed.

My perfect solution will be one that does not invlove opeing the file... as I know if you open the file you will have access exclusively to it... but this method makes it uneditable to other processes.. (not what I want)

Please help.

thankyou
 
I'd like to help, but sadly I'm far too busy working on something that will
stop people posting the same message to the same newsgroup twice within an
hour and a half.


BuzzLight said:
Hello, I would like my program to somehow lock a file on the file system
.... say c:\myfile.mdb... so when the program is running the file is
un-moveable, but NOT un-editable, This is to prevent users from moving the
file during program execution.. which would lead to alot of errors in the
program if it were allowed.
My perfect solution will be one that does not invlove opeing the file...
as I know if you open the file you will have access exclusively to it... but
this method makes it uneditable to other processes.. (not what I want)
 
* "Rob Oldfield said:
I'd like to help, but sadly I'm far too busy working on something that will
stop people posting the same message to the same newsgroup twice within an
hour and a half.

The subject changed...
 
Back
Top