Description:
Here is how you can take Ownership of a file, folder, registry key, or drive in Windows Vista where you have been denied access to allow you to give full control of it so that you will be able to delete or modify this item. When you do this, you replace the security permissions to have access.

Note:
You will quickly notice that you cannot delete or modify system files, even as a administrator in Windows Vista. This is because Vista system files are owned by the TrustedInstaller service by default which is its feature, and Windows File Protection will keep them from being overwritten. You will encounter a "Access Denied" error.

Follow the instructions below:

EXAMPLE: You will need permission to perform this action.

NOTE: You will see this Access Denied with the Try Again type message when your user account or group does not have Ownership of the file. Clicking on the Try Again does nothing.


1. Open the Start Menu.

2. In the white line (Start Search) area, type cmd.

3. Right click cmd (at top) and click Run as administrator.

4. Click Continue button for UAC prompt.

5. In command prompt, type takeown /f (full path of file)
NOTE: Substitute (full path of file) with your file's full path.
EX: takeown /f C:\Windows\System32\en-US\winload.exe.mui

6. Press Enter.

7. A message will be displayed that this completed successfully. This will give you ownership of the file.

8. In same command prompt, type icacls (full path of file) /grant (your username):F
NOTE: Substitute (full path of file) with your file's full path and (your username) with your current username.
EX: icacls C:\Windows\System32\en-US\winload.exe.mui /grant Micky:F

9. Press Enter.

10. A message will be displayed that this completed successfully.
NOTE: You should be able to delete or modify the file now. If you still can't, you may need to reboot into Safe Mode and try this again. It may vary according to the file. Some are more stubborn.