Cannot Delete DCxxx--Access Denied

When I attempt to empty the recycle bin, Windows tells me, "Cannot Delete DCxxx, Access Denied." When I look in the recycle bin, it's empty.

In Windows XP Pro, I recently ran into this situation. 

One Possible Solution From One Online Forum:

If the recycle bin appears empty, even though you've been deleting files . . . and you receive a message like the above, try the following:

  • Check to see if your machine is infested with some sort of spyware or virus. Use the appropriate anti-spyware and antivirus tools to clear out anything found.
  • Open My Computer
  • If system files are hidden by default, click Tools then Folder Options, then click on the View tab. Scroll down and uncheck Hide Protected Operating System Files. Click Yes, then OK.
  • Look for C:\Recycled--or whatever your recycle bin is called--and delete it. Repeat this step for any other drives you have on your system (e.g., .D:\Recycled, E:\Recycled, etc.)
  • Reboot the computer.

Windows will recreate all those Recycler files you just deleted, and you should be good to go.

I didn't want to do this without first checking out all other options; but this sounded like a strategy I might be ultimately using. But I looked for other solutions on the web and found a few more.

 

Another Possible Strategy From the Microsoft Knowledge Base:


      CAUSE

      By design, files deleted by network clients never go into the Recycle Bin, so make sure the files in question were deleted locally

      Permissions on the C:\Recycled directory may be too restrictive.

      RESOLUTION

      Administrators should have ownership of the Recycled directory. To take ownership of the directory, perform the following: . . .


This wasn't my problem; I had all the necessary permissions

Another Possible Strategy:

I found this:


  • Ensure there's something in the Recycle Bin; delete a file, if necessary.
  • Right click on the Recycle Bin and click on Empty Recycle Bin.
  • When the confirm box appears, click OK.
  • Reboot the computer. Now the Recycle Bin should work correctly.

If the above didn't work and your hard drive is formatted as FAT32, then the Recycle Bin may have a corrupt info2 file. Do the following:

  • Click on Start, then Run and type CMD in the blank that appears
  • Type cd .. until you see a C:\> prompt
  • Type CD \RECYCLED, and then press <Enter>
  • Type ATTRIB -r -s -h info2, and then press <Enter>.
  • Type DEL INFO2, and then press <Enter>.

Windows will automatically recreate this file.


The first procedure didn't work for me, and my hard drives are formatted NTFS, not FAT32. I began to wonder if the Info2 file existed on an NTFS hard drive.

Yet Another Possible Strategy

I wondered if I could view the offending file DC135, which obviously was hidden in some fashion since I couldn't see it by double-clicking on the recycle bin icon.

If I could actually see the file, I might then be able to reboot in safe mode or use a special boot disk I'd created to ultimately delete the file.

Here were two explanations that I found on the web that might set me up to do this.

    To see the files listed in the Recycled Folder

    • Click on Start
    • Click on Run and type in:  CMD
    • At the prompt type in:  cd\ and press <Enter>
    • cd Recycled and press <Enter>
    • dir and press <Enter>

    The hidden folder created on each volume, on which the recycle bin option is enabled, is named Recycled. All your deleted files are moved to this folder and renamed following the following naming convention:

      C<original drive letter><number file deleted>.<original extension> and the original full name and path stored in a mapping file Info2.

    For example, the file name:  C:\www.painter.com\index.html, if it was originally the first file deleted on drive C, would become Dc1.html. If the file were originally the 25th file deleted on drive D, the deleted file would then be renamed and listed as Dd25.html, etc.

    To Recover Files in NTFS:

    • Click Start, Run and enter %systemdrive%\Recycled.  Under this folder you'll see sub folders with names like S-1-5-21-1085031214-854245398-1060284298-1003. One of these is your user's Recycle Bin folder, you'll have to determine which.  Then open a Command Prompt Window and type: Start/Run and type in: CMD
    • CD\Recycled\<name of the sub folder>
    • Next type DIR

The critical information from the latter set of instructions was wthat the subdirectory underneath Recycler was called. That's where the actual DCxxx files were located. Was there also an INFO2 file in that subfolder that I would have to delete? I decided to research further, and found this:

    Error Message while deleting:

    If, while attempting to empty the recycle bin, you receive an odd error, you may have inadvertently opened a file or folder that has a share lock on a file or folder that you are attempting to delete. This usually occurs when attempting to browse your hard drive in Explorer. Close Explorer and then retry emptying the Recycle Bin.

Now this made sense, but Explorer--or in my case Directory Opus--wasn't open. In addition, I had no way of checking to see what program or process owned control of the file, because I couldn't--as yet--see the file in the recycle bin. So I decided to look for further strategies. If need be, once I could actually see the DC135 file, I could see if the problem was just a simple file lock.

And Another Strategy:

Could I somehow uninstall the recycle bin and then reinstall it by:

  • Right clicking on the Recycle Bin,
  • Selecting Properties and set the slider to 0%.
  • Logging off, then logging back in.
  • Checking to see if the file was finally gone
  • Resetting the Recycle Bin size to 10% or whatever, and, then
  • Logging off and back in again?

This might be worth trying; and it certainly had the virtue of being simple to do. 

The Solution I Arrived At:

Then, out of the blue, a thought hit me. [Don't ask me where this came from because I can't tell you. My subconscious often seems to give me flashes of insight when I least expect them. After 44 years working with computers, I trust "my instincts".] I had a sneaking suspicion that the recycle bin registry key(s) had somehow been corrupted. So just for the heck of it, I decided to follow that intuition. I went looking, found the following, and clicked on the link:

    Replace/Repair the Recycle Bin  This is a REG file. Save the file to your hard disk and double click it. Answer yes to the import prompt.  Right click on the Desktop and select Refresh. REG files can be viewed in Notepad by right clicking the file and selecting Edit.

So I double-clicked on the .reg file and got confirmation that the registry key had been installed. Then I logged off and back on again. Problem solved. <g>

Back to Top

arrowl2 Return to Software Fixes & Workarounds

 

Comments

 

Latest Version! NetObjects Fusion 10 

 

Copyright 1998 Rich Hamper 

All Rights Reserved

 

Last Updated:

Sunday, January 20, 2008