How to remove write-protection on a folder

B

Bob

Hi. I am using XP Home 5.1, SP3. I usually have no problem creating and
deleting folders in the My Documents directory. But in some cases, when I
try to delete a folder, I get the error message "cannot delete folder. the
storage is write-protected".

I have deleted all the documents within the folder, but still get the same
message. I checked in Properties, and the folder is not marked as Read-Only.
But somehow XP thinks the folder is write-protected. There are no other
applications running on the PC at the time that I try to delete the folder,
and there are no hidden files in the folder.

Does anyone know how to remove the write-protection from a folder so that I
can delete it? Thx
 
P

Pegasus [MVP]

Bob said:
Hi. I am using XP Home 5.1, SP3. I usually have no problem creating and
deleting folders in the My Documents directory. But in some cases, when I
try to delete a folder, I get the error message "cannot delete folder.
the
storage is write-protected".

I have deleted all the documents within the folder, but still get the same
message. I checked in Properties, and the folder is not marked as
Read-Only.
But somehow XP thinks the folder is write-protected. There are no other
applications running on the PC at the time that I try to delete the
folder,
and there are no hidden files in the folder.

Does anyone know how to remove the write-protection from a folder so that
I
can delete it? Thx

Windows ignores the write-protection attribute of folders. If you are unable
to delete a folder then this is because there is some hidden and
write-protected file inside. If you instruct Explorer to show hidden files
then you can see them and deal with them.
 
B

Bob

Yes, I set the Windows Explorer setting to "show hidden files and folders",
but still do not see any files in the folder that I am trying to delete ...
 
T

Twayne

Bob said:
Hi. I am using XP Home 5.1, SP3. I usually have no problem creating
and deleting folders in the My Documents directory. But in some
cases, when I try to delete a folder, I get the error message "cannot
delete folder. the storage is write-protected".

I have deleted all the documents within the folder, but still get the
same message. I checked in Properties, and the folder is not marked
as Read-Only. But somehow XP thinks the folder is write-protected.
There are no other applications running on the PC at the time that I
try to delete the folder, and there are no hidden files in the folder.

Does anyone know how to remove the write-protection from a folder so
that I can delete it? Thx


If I've gauged your level of expertise to be lower than it is, please
excuse it; it's easier to include all the data than to assume you know
things I don't mention:

There are two more to check: In windows Explorer, click Tools, Folder
Oprions, the View tab,
Tick: Show hidden files and folders
Untick: Hide Extensions for Known File Types
Untick: Hide Protected Operating System Files

Caveat: The first and last ones in particular now allow you to delete,
move and mess around with some files that are critical and which
deleting or moving would crash your machine. In some cases you might
delete them and then find they are recreated.
Since you aren't highly experienced yet, you should probably return
those 3 settings to their defaults after you're done trouble-shooting.

If the file you can't delete is set as a "system folder", then windows
wouldn't allow you to delete it. You might find a "layout.ini" or
another I can't think of right now listed because it's a system folder.
Deleting a system folder can cause some pretty annoying headaches or
even screw up the machine, so be thoughtful about it.
IF it's a folder YOU created however, on your own, then it's not
going to be a system folder regardless of how it's marked. So if you're
certain it's a folder you created, go ahead and kill everything in it,
and then try to delete the folder again.

A folder YOU created is OK to delete.
A folder Windows created may not be safe to delete; proceed with
caution. This would be a good time to update your backups, just in case
"stuff" happens.

At a minimum now, you should have enough information to more accurately
pick out the details to add to your post; name of the folder, whether it
contains any .ini, ,msi, etc., files, your XP version, and anything else
you can think of that might be relevent. Better too much information
than too little as a rule.

HTH,

Twayne`
 
P

Pegasus [MVP]

Since I cannot see your machine I cannot tell you how to make the required
settings in Explorer but I can tell you how to deal with the problem folder
using Console commands. Let's assume that your "protected" folder is called
"c:\documents and settings\bob\desktop\xxx". Here is what you do:
1. Click Start / Run
2. Type the three letters cmd
3. Click the OK button.
4. Type the following commands *verbatim* and press
Enter after each of them:
attrib /s "c:\documents and settings\bob\desktop\xxx"
{Can you see your hidden files? What attributes do they have?}
rd /s /q "c:\documents and settings\bob\desktop\xxx"
{This command will unconditionally delete the problem folder.
It will NOT go into the Recycle Bin and cannot be restored.
Make doubly sure that you spell it correctly.}
If you are still unable to delete the folder, reboot into Safe Mode and try
the above steps again.
 
B

Bob

Thank you all! Problem solved ...

Twayne said:
If I've gauged your level of expertise to be lower than it is, please
excuse it; it's easier to include all the data than to assume you know
things I don't mention:

There are two more to check: In windows Explorer, click Tools, Folder
Oprions, the View tab,
Tick: Show hidden files and folders
Untick: Hide Extensions for Known File Types
Untick: Hide Protected Operating System Files

Caveat: The first and last ones in particular now allow you to delete,
move and mess around with some files that are critical and which
deleting or moving would crash your machine. In some cases you might
delete them and then find they are recreated.
Since you aren't highly experienced yet, you should probably return
those 3 settings to their defaults after you're done trouble-shooting.

If the file you can't delete is set as a "system folder", then windows
wouldn't allow you to delete it. You might find a "layout.ini" or
another I can't think of right now listed because it's a system folder.
Deleting a system folder can cause some pretty annoying headaches or
even screw up the machine, so be thoughtful about it.
IF it's a folder YOU created however, on your own, then it's not
going to be a system folder regardless of how it's marked. So if you're
certain it's a folder you created, go ahead and kill everything in it,
and then try to delete the folder again.

A folder YOU created is OK to delete.
A folder Windows created may not be safe to delete; proceed with
caution. This would be a good time to update your backups, just in case
"stuff" happens.

At a minimum now, you should have enough information to more accurately
pick out the details to add to your post; name of the folder, whether it
contains any .ini, ,msi, etc., files, your XP version, and anything else
you can think of that might be relevent. Better too much information
than too little as a rule.

HTH,

Twayne`
 
T

Twayne

Bob said:
Yes, I set the Windows Explorer setting to "show hidden files and
folders", but still do not see any files in the folder that I am
trying to delete ...

There are two more to check: In windows Explorer, Tools, Folder
Oprions, the View tab,
Tick: Show hidden files and folders
Untick: Hide Extensions for Known File Types
Untick: Hide Protected Operating System Files

Caveat: The first and last ones in particular now allow you to delete,
move and mess around with some files that are critical and which
deleting or moving would crash your machine. In some cases you might
delete them and then find they are recreated.
Since you aren't highly experienced yet, you should probably return
those 3 settings to their defaults after you're done trouble-shooting.

If the file you can't delete is set as a "system folder", then windows
wouldn't allow you to delete it. You might find a "layout.ini" or
another I can't think of right now listed because it's a system folder.
Deleting a system folder can cause some pretty annoying headaches or
even screw up the machine, so be thoughtful about it.
IF it's a folder YOU created however, on your own, then it's not
going to be a system folder regardless of how it's marked. So if you're
certain it's a folder you created, go ahead and kill everything in it,
and then try to delete the folder again.

A folder YOU created is OK to delete.
A folder Windows created may not be safe to delete; proceed with
caution. This would be a good time to update your backups, just in case
"stuff" happens.

At a minimum now, you should have enough information to more accurately
pick out the details to add to your post; name of the folder, whether it
contains any .ini, ,msi, etc., files, your XP version, and anything else
you can think of that might be relevent. Better too much information
than too little as a rule.

HTH,

Twayne`
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top