Jump to content
Sign in to follow this  
zzen11

Force delete a file or directory being used

Recommended Posts

zzen11

Is there a way to force delete a file that is locked by another process?

Share this post


Link to post
Share on other sites
Nova

Do u mean for example deleting a file myprog.exe while its running ?

You cant delete a program while its running.

This will however work

Processclose("myprog.exe")
filedelete(@scriptdir & "\myprog.exe")
Edited by Nova

Share this post


Link to post
Share on other sites
zzen11

Is there a way to force delete a file that is locked by another process?

<{POST_SNAPBACK}>

I mean:

Myprogram.exe is running, and it has a openfile: myfile.dat, and I may not even know which exe is opening the myfile.dat.

I want to force delete myfile.dat

Edited by zzen11

Share this post


Link to post
Share on other sites
buzz44

I mean:

Myprogram.exe is running, and it has a openfile: myfile.dat, and I may not even know which exe is opening the myfile.dat.

I want to force delete myfile.dat

<{POST_SNAPBACK}>

u wont be able to delete it aslong as it is in use by another process.

qq

Share this post


Link to post
Share on other sites
this-is-me

You can use one of the UDFs to delete the file once the computer is rebooted. You can also do some creative uses of the program wholockme to find out which program has the file open and kill that program.


Who else would I be?

Share this post


Link to post
Share on other sites
sykes

You can use one of the UDFs to delete the file once the computer is rebooted. You can also do some creative uses of the program wholockme to find out which program has the file open and kill that program.

<{POST_SNAPBACK}>

Nice program this-is-me ... Thanks for sharing that info

We have enough youth. How about a fountain of SMART?

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
Sign in to follow this  

×