How To Override “Access Denied” and “Sharing Violation” Roadblocks
(using two utilities: "Unlocker" and "Move on Boot")
That vexing message !!! “Cannot delete file: Access is denied.”
That’s a message often pops up in Windows when you’re trying to delte a file that doesn’t want to be killed. Other roadblocks include “There has been a sharing violation,” “The file is in use by another program or user,” and “Make sure the disk is not full or write-protected and that the file is not currently in use.”
Typical culprits include no-longer-welcome antivirus software, security programs and home-built code that didn’t properly close an open file on exit. In response, some try incrementally closing running processes, one at a time, till whatever was holding them up lets loose. Others continually reduce items in Startup then reboot, again and again. Sometimes it works, sometimes it doesn’t.
There are a couple of better and easier ways to bypass these errors, kill the desired program, and go on about your business. And amazingly, they’re free.
Who Lock Me
Find out what Process is Locking the File or Folder - http://www.dr-hoiby.com/WhoLockMe/ (will not work on Win95 or WinME
Unlocker
Unlock the file or folder. The first utility, Unlocker, adds a right-click option that lists running processes and allows you to pick items to unlock for access or deletion.
Keep in mind that many running processes cannot be interrupted without screwing up your system. So it’s up to you to choose wisely. You can download the latest version of Unlocker at the author’s site. (Installation tip: To prevent Unlocker from automatically contacting its update server, you must unclick “Check for Updates” when you install it.)
Move on Boot
(may not be necessary - read the "Update info)
If Unlocker doesn’t get the job done, try MoveOnBoot. As the name implies, MoveOnBoot renames, moves or deletes the offending file(s) when you reboot. It even helps you remove files that can’t be deleted in Safe Mode, including the occasional virus file that a/v software can’t kill. The most current freeware version of MoveOnBoot can be downloaded at Softpedia.
Together, Unlocker and MoveOnBoot can help you finish the job when standard procedures like Uninstall don’t.
Update Info !!! One user replied: "You do not need move on boot. If unlocker fails, it will propose to process the operation at next boot. It does it the exact same way that move on boot does. Using the same registry keys. So move on boot is now redundant.
Other Utilities worth Mentioning
Filemon (Sysinternals) - http://www.sysinternals.com/Utilities/Filemon.html
Danjou’s “Locked Files Wizard - http://noeld.com/programs.asp?cat=misc - not only is is wizard-based for deletion, move or delete at reboot actions, it also comes with a command line version as well.