lesa
asked on
Verifying whether the file is opened before deleting
I have a situation in which I am deleting a file using Kill(Path), but before deleting the file I need to check whether the file is opened by user through another application so that I can prompt the user that the file is in use before deleting. How can I achieve it.
Briefly how can I check whether the file is opened by some other application. File may be of any extension like .xls, .doc, .txt.
Briefly how can I check whether the file is opened by some other application. File may be of any extension like .xls, .doc, .txt.
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
This is the only solution. To know if the file is open, you need to access it. There is nowhere a property set telling that the file is currently openend.
ASKER