Remove read-only attribute from folder after Windows reinstall
I reinstalled a fresh copy of Windows 8.1 on my laptop after formatting drive C
. Then I tried to access my Photos folder on drive D
and got the error
Access is denied
It turned my folder into a Read Only folder. All other folders on the drive work normally.
I tried using Command Prompt to remove the Read Only attribute but the error message still appears. I tried doing it the simple way (right-click and so on) but the option to change the folder properties from read-only doesn't even appear.
How do I access the folder on my D drive?
Solution 1:
The problem isn't that the folder is Read Only. Rather, because your folder was created on a different installation of Windows you no longer have NTFS security permissions to access (read) the folder.
Correct this by following these steps to take ownership and then grant yourself full access to the folder.
- Right-click the folder > Properties
- Security tab > Advanced
- Click Change to the right of Owner
- Enter
Users
into box and click OK - Enable the checkbox Replace owner on subcontainers and objects then click Apply
- If prompted that You do not have permissions to read... click Yes
- Completely close out of the Advanced Security Settings dialog
- Right-click the folder > Properties
- Security tab > Edit...
- Add...
- Enter
Users
into box and click OK - Enable the Full Control checkbox then click OK
Solution 2:
Do this in CMD as admin
for the folder
attrib -r c:\my-folder
and the files
attrib -r c:\my-folder\*.*
It did the job. I was having issue with PhpStorm. It wasn't able to save the project files because of the read-only status. After doing this in CMD as admin, all is well.
I posted this in Microsoft forum as well - http://answers.microsoft.com/en-us/windows/forum/windows_8-files/in-windows-8-x64-can-not-remove-read-only/81ed233f-9149-4881-bb15-cf0e1ca150e3