Move file in use , who is blocking it or using it , force move delete

We’ve all experienced it sometime: A file or folder is in use, and windows refuses to move or delete it. Even though it should, Windows rarely shows us what or who is blocking the file. Left in the dark, you’ll end up closing all sorts of apps, killing explorer, and what not. Then there are those cheesy apps, like “who’s blocking”, that do all but free the file. So.. there we are.

A few days ago, I stumbled upon a small command line app from Mark Russinovich. Now, that sounds like a guy who knows how to kill a blocking app. 😉 (just kiddin’). In fact, his app called “handle” is featured at Windows Sysinternals. Here is what it did for me.

I had this demo of Mixmeister and I wanted to “move” the downloaded install-file-folder to my backup drive. But somehow it was blocked. Windows, endlessly informative, told me nothing that I could use:

inuse1

So I fired up HANDLE. I asked it to tell me who’s blocking Mixmeister.

Handle mixmeister

I then got a list of “handles”, two of them were explorer and one of them was my browser chrome. To chase these apps away from my folder (file), I needed the PID of the app and the handle on the file. Handle provides both. In my case, explorer had pid 3796 and the handle on my folder had 1978. I could now get it off by entering:

Handle -c 1978 -p 3796

inuse2

I did the same for the other two handles, and see there: The folder was free and I could move it quite happily.

Just remember: Killing handles “can” crash your machine. When attempting this, always make sure any unsaved data is saved!

You can download HANDLE from here.

1 thought on “Move file in use , who is blocking it or using it , force move delete

  1. I had a problem I could not delete a big file (export.MHTML) on my desktop. The file creation process aborted. Also, I notices since then, the explorer process was using most of my CPU.
    Here’s how I solved this (without admin rights):

    1. Open Command window and tried “DEL export.mhtml” which was of course not possible => error msg “the process cannot access the file because it is being used by another process”
    2. Open the Task manager and stopped process explorer.exe
    3. Back in command window, I could now successfully delete the file

    After this, my CPU load was back to normal

    Regards
    Peter

Leave a Comment