Access denied to a folder that I want to delete

jmt356
SilverLounger
Posts: 2382
Joined: 28 Mar 2010, 01:49

Access denied to a folder that I want to delete

Post by jmt356 »

I have a folder on an external hard drive that I would like to delete. When I try to detete it, Windows requires me to provide administrative permission to continue. I click Continue, but then get an Access denied error.

I right clicked on the folder, gone to the Security tab, clicked on Advanced, and gave myself full control over the folder (including the power to delete it). However, whenever I try deleting it, the above process repeats.

How can it be deleted?
Regards,

JMT

User avatar
Leif
Administrator
Posts: 7208
Joined: 15 Jan 2010, 22:52
Location: Middle of England

Re: Access denied to a folder that I want to delete

Post by Leif »

Is this related to your Windows Explorer not displaying free space accurately post?

i.e. - are you trying to delete $RECYCLE.BIN?
Leif

User avatar
Timelord
4StarLounger
Posts: 504
Joined: 23 Jul 2010, 18:36
Location: Westlake, OHIO

Re: Access denied to a folder that I want to delete

Post by Timelord »

Did you delete the contents first? I have run into problems in the past where when I delete the contents of the folder and then try to delete the folder I cannot. This is usually fixed with the next time I reboot my computer. Windows seems to hold the 'session' after the delete is finished. Also, make sure that you can see hidden and system files. Those could be stopping the delete of a folder if they are open by another program.
Who will you Inspire today?

jmt356
SilverLounger
Posts: 2382
Joined: 28 Mar 2010, 01:49

Re: Access denied to a folder that I want to delete

Post by jmt356 »

Leif, it is related to the other post, but I'm not trying to get rid of $RECYCLE.BIN; I'm trying to delete a visible folder, yet I am denied access.

Timlord, I did delete the contents first, only because the top folder would not delete on its own. I'm not sure restarting would help; I have tried deleting this folder by connecting the external hard drive to two different computers, and both computers give me the same Access denied error.
Regards,

JMT

jmt356
SilverLounger
Posts: 2382
Joined: 28 Mar 2010, 01:49

Re: Access denied to a folder that I want to delete

Post by jmt356 »

I did a restart, yet I still can't delete the folders. There is one called Windows and another called Program Files. I think I copied them to the external hard drive from one of my computers.
Regards,

JMT

User avatar
HansV
Administrator
Posts: 78402
Joined: 16 Jan 2010, 00:14
Status: Microsoft MVP
Location: Wageningen, The Netherlands

Re: Access denied to a folder that I want to delete

Post by HansV »

Both Windows and Program Files are the names of system folders. Windows will prevent you from deleting those.
Are you REALLY sure that you want to delete these folders? If so, try the following:

- Start a command prompt window (Start > Accessories > Command Prompt).
- Type RD \\.\H:\Windows where H: is the drive letter of your external drive, then press Enter.
- Type RD \\.\H:\Program Files where H: is the drive letter of your external drive, then press Enter.
- Close the command prompt window.

(Source: How to Remove Files with Reserved Names in Windows)
Best wishes,
Hans

jmt356
SilverLounger
Posts: 2382
Joined: 28 Mar 2010, 01:49

Re: Access denied to a folder that I want to delete

Post by jmt356 »

These aren’t really program files. They are just the names of folders that I put on my external hard drive. I have another external hard drive and it doesn’t have such folder names on it. The only folder names that both of them have in common are $RECYCLE.BIN, RECYCLER, and System Volume Information. I suppose all of these are system folders.

I tried the above suggestion and here is what happened:
For F:\Windows, "the directory is not empty" appeared after I pressed enter.
For F:\Program Files, "The system cannot find the file specified" appeared after I pressed enter.
For F:\Test (a test folder I created), I was able to delete the folder.
Regards,

JMT

User avatar
Argus
GoldLounger
Posts: 3081
Joined: 24 Jan 2010, 19:07

Re: Access denied to a folder that I want to delete

Post by Argus »

jmt356 wrote:I tried the above suggestion and here is what happened:
For F:\Windows, "the directory is not empty" appeared after I pressed enter.
For F:\Program Files, "The system cannot find the file specified" appeared after I pressed enter.
For F:\Test (a test folder I created), I was able to delete the folder.
Why is there a difference between example one and two, you think?
There is a space in the path, there is no: F:\Program.
Byelingual    When you speak two languages but start losing vocabulary in both of them.

User avatar
HansV
Administrator
Posts: 78402
Joined: 16 Jan 2010, 00:14
Status: Microsoft MVP
Location: Wageningen, The Netherlands

Re: Access denied to a folder that I want to delete

Post by HansV »

Try

RD /S /Q "\\.\F:\Windows"
RD /S /Q "\\.\F:\Program Files"
Best wishes,
Hans

User avatar
DaveA
GoldLounger
Posts: 2599
Joined: 24 Jan 2010, 15:26
Location: Olympia, WA

Re: Access denied to a folder that I want to delete

Post by DaveA »

They are just the names of folders that I put on my external hard drive.
If you "Copied" these folder from the System drive then they are "System folder". BUT, if you made the folders and typed in the folder names, then you should be able to delete them.

How did you make these folders on this drive?
I am so far behind, I think I am First :evilgrin:
Genealogy....confusing the dead and annoying the living

jmt356
SilverLounger
Posts: 2382
Joined: 28 Mar 2010, 01:49

Re: Access denied to a folder that I want to delete

Post by jmt356 »

I believe I copied these folders from the hard drive of one of my computers, but I cannot remember. Yet even if I did, I feel there must be some way to delete them.

When I tried following Hans’ suggestion in Post 72442, I got “Access is denied” for several files within each of the folders (Windows and Program Files) that I was trying to delete (screen shots to the messages attached).

There are three files in the Windows folder that Windows says I do not have permission to delete. Moreover, Windows believes that there are four files in the Program Files folder that I do not have permission to delete, but this appears to be an errors because the Windows folder is completely empty (even when I have hidden files and folders made visible).

Has anyone developed a program that can overcome all of Windows’ restrictions and delete files on an external hard drive per my instructions?
Command Prompt 2.jpg
You do not have the required permissions to view the files attached to this post.
Regards,

JMT

User avatar
HansV
Administrator
Posts: 78402
Joined: 16 Jan 2010, 00:14
Status: Microsoft MVP
Location: Wageningen, The Netherlands

Re: Access denied to a folder that I want to delete

Post by HansV »

Does it make a difference if you start a command prompt with Administrator rights (a so-called elevated command prompt)?

For Windows Vista/7: How to start an Elevated Command Prompt in Windows 7 and Vista.
For Windows 8/8.1: How To Open an Elevated Command Prompt in Windows 8 & 8.1.
Best wishes,
Hans

User avatar
Claude
cheese lizard
Posts: 6241
Joined: 16 Jan 2010, 00:14
Location: Sydney Australia

Re: Access denied to a folder that I want to delete

Post by Claude »

Looks to me like they (those files) are in use. Try booting in safe mode, then delete them. And while you're in safe mode, empty the temporary folders as well.
Cheers, Claude.

User avatar
viking33
PlatinumLounger
Posts: 5685
Joined: 24 Jan 2010, 19:16
Location: Cape Cod, Massachusetts,USA

Re: Access denied to a folder that I want to delete

Post by viking33 »

You can also use the free utility called "Unlocker"
Check it out and download it HERE
I have used it successfully many times and it usually does the job.
BOB
:massachusetts: :usa:
______________________________________

If I agreed with you we'd both be wrong.

User avatar
DaveA
GoldLounger
Posts: 2599
Joined: 24 Jan 2010, 15:26
Location: Olympia, WA

Re: Access denied to a folder that I want to delete

Post by DaveA »

What is this "Y" drive that these files are on?

If it is a system drive, then these files are protected.
I am so far behind, I think I am First :evilgrin:
Genealogy....confusing the dead and annoying the living

User avatar
viking33
PlatinumLounger
Posts: 5685
Joined: 24 Jan 2010, 19:16
Location: Cape Cod, Massachusetts,USA

Re: Access denied to a folder that I want to delete

Post by viking33 »

DaveA wrote:What is this "Y" drive that these files are on?

If it is a system drive, then these files are protected.
Apparently, these are copies made to an external HD ( almost two years ago, going by the post date?) 2012 guess he named it Y drive? If he can't delete them through Windows, then Unlocker should be able to do it. :shrug:
BOB
:massachusetts: :usa:
______________________________________

If I agreed with you we'd both be wrong.

User avatar
John Gray
PlatinumLounger
Posts: 5405
Joined: 24 Jan 2010, 08:33
Location: A cathedral city in England

Re: Access denied to a folder that I want to delete

Post by John Gray »

I would warn anyone installing Unlocker to watch the installation like a hawk, in case it attempts to download malware, toolbars, etc, as well as the highly-useful Unlocker program.
It took me half an hour to remove rubbish after an installation a few weeks' ago, and I think I got the file from Cedrick Collomb's website emptyloop.com...
John Gray

"(or one of the team)" - how your appointment letter indicates you won't be seeing the Consultant...

User avatar
viking33
PlatinumLounger
Posts: 5685
Joined: 24 Jan 2010, 19:16
Location: Cape Cod, Massachusetts,USA

Re: Access denied to a folder that I want to delete

Post by viking33 »

John Gray wrote:I would warn anyone installing Unlocker to watch the installation like a hawk, in case it attempts to download malware, toolbars, etc, as well as the highly-useful Unlocker program.
It took me half an hour to remove rubbish after an installation a few weeks' ago, and I think I got the file from Cedrick Collomb's website emptyloop.com...
I've never had any problem with Cedrick's website or his programs. They haven't contained any nasty side effects like you describe. I've updated from his site just recently and all was fine. Sure it wasn't a spoof site, John? :scratch:
BOB
:massachusetts: :usa:
______________________________________

If I agreed with you we'd both be wrong.

User avatar
John Gray
PlatinumLounger
Posts: 5405
Joined: 24 Jan 2010, 08:33
Location: A cathedral city in England

Re: Access denied to a folder that I want to delete

Post by John Gray »

I thought it was his site, but maybe I clicked on the wrong Google hit...
John Gray

"(or one of the team)" - how your appointment letter indicates you won't be seeing the Consultant...

jmt356
SilverLounger
Posts: 2382
Joined: 28 Mar 2010, 01:49

Re: Access denied to a folder that I want to delete

Post by jmt356 »

The Y drive is an external hard drive whose assigned drive letter is “Y.”
Unlocker sounds like it might do the trick, but has anyone inadvertently downloaded malware while downloading the product from http://www.emptyloop.com/unlocker/" onclick="window.open(this.href);return false;? I already had to deal with many difficult malware issues when I downloaded Babylon Dictionary and I don’t have a half hour to try to uninstall such malware.
Regards,

JMT