How to unlock locked files?

Windows specific forum
Dare2
Moderator
Moderator
Posts: 3321
Joined: Sat Dec 27, 2003 3:55 am
Location: Great Southern Land

Post by Dare2 »

Hi Michael,

I am not sure it I am talking through my hat here, or if this is feasible for you, but if the file stays locked until the locker program quits, can you shell out to another prog to do the copy. (And hide your main app). Then if the copy is aborted, the small utility prog quits and frees the file.

Or am I way off beam?

Anyhow, hope you find a solution soon as this is obviously hindering you. Success!
@}--`--,-- A rose by any other name ..
User avatar
Michael Vogel
Addict
Addict
Posts: 2821
Joined: Thu Feb 09, 2006 11:27 pm
Contact:

Post by Michael Vogel »

Dare2 wrote:...if the file stays locked until the locker program quits, can you shell out to another prog to do the copy...
Not very elegant...

...as the copy routine itself is the reason for the lock, the actually written (and so locked) file is only known exactly in that (external) routine, so it would be necessary to do a external file to write a log (cool, another file to unlock :D) or the external program would have to be executed for each file seperately, a lot of overhead just for the point to have a threadsafe file copy, isn't it?

...but a reason, why brute force methods get sometimes popular :roll:
Post Reply