Subscribe to How-To Geek

Recommended: Click Here to Run a Free Scan for Common PC Errors   [Sponsored Link]

Add "Take Ownership" to Explorer Right-Click Menu in Vista

Taking ownership of system files or folders in Windows Vista is not a simple task. Whether you use the GUI or the command line, it takes far too many steps.

Thankfully somebody created a registry hack that will give you a menu item for "Take Ownership" that will handle all the steps for you.  (If you are the person that originally made this script, let me know and I'll give you credit)

Here's what the new right-click menu will look like after installing this registry hack.

image 

Install

Download and unzip the files contained in the zipfile. Double-click the InstallTakeOwnership.reg file and click through the prompts. No reboot necessary.

image

Uninstall

Double-click the RemoveTakeOwnership.reg file and click through the prompts. No reboot necessary.

 

Download TakeOwnership.zip

The Geek is the founder of How-To Geek and a geek enthusiast. When he's not coming up with great how-to articles, he's probably writing at his personal blog. This article was written on 06/3/07 and tagged with: Windows Vista, System Administration

Comments (31)

  1. huh?

    All I get when I double-click the extracted InstallTakeOwnership.reg file is the window asking me what program do I want to open it with. What do I need to do?

  2. CypherBit

    Nice indeed. Any reason why it says how to do this in Vista only? Have there been any drastic changes from 2k/XP/2k3, can anyone verify if this works on all recent MS OS's?

  3. jacobian

    what does it do exactly? i installed it and everything seems fine but what does "taking ownership" mean.
    is it just like hiding or encrypting a folder?

  4. Mr Linux

    http://www.winmatrix.com/forum.....opic=13157 (original source as far as I can tell)

    Taking ownership of a file/directory gives you direct read/write access to the file (without going through UAC) and forces other users to go through UAC to get such access. Now that Vista finally has a sane notion of file ownership (like Linux and Mac have had for years), this sort of thing comes in major handy (especially when you often change files like C:\WINDOWS\system32\drivers\etc\HOSTS).

  5. FireMaiden

    Oh my God, this Take Ownership feature is awesome. Many thanks to the creator.

  6. GoldenEagle \\ Pablo

    Thanks for this! We were having issues after the Belkin Easy Transfer Cable messed all the permissions up and after trying several times with Vista's ownership nothing had worked. This worked first time!

  7. DT

    I spent way too many hours today trying to get our personal.xls with custom macros into the XLStart folder so we could do billing today (prior XP pc fried, new pc is Vista). Needless to say, Vista gives me no rights to XLStart folder and I'm just so glad I found this zip fix here tonite. Can't wait to try tomorrow! Many thanks. And Microsoft — get a grip, I'm tired of having Mac folks tell me to buy a Mac! Don't make our lives harder!!! Or you'll find us all on MAC…

  8. mu12345

    I can't take the ownership of the C drive. But I can take the ownership of the folders in C drive. Any comment?

  9. mike v

    Ok Guys…..I really screwed up.(that's what usually happens when you don't know what your doing) I was trying to gain access to my entire drive so I could delete temp files/temp internet files etc. So, after reading this post on how to delete system files I used this in the command prompt: [takeown / C:\ f ] afterwhich it said that my-acer had owership….Cool so far….I think. Then I used the cacls command: [cacls C:\ *.* /G my-acer:F] I was asked if I was sure & answered yes,hit return & it said the process was successful. Now I can't get many things to run at all & if I attempt to use the command line as an admin I get this:"c:\windows\system32\cmd.exe the parameter is incorrect". I get the same sort of message when I try & run other things. I have to also say that when I login to start windows my name is "ironhorse" & the name of the pc is "my-acer". A friend told me I need to give full rights to both of these names if I want to delete certain files as their considered administrators(both me of course). I haven't restarted the machine cause I know it will never restart so I'm trying to get this fixed through the command prompt. I tyred to roll back through system protection but can't get there either. Am I screwed or is this fixable. Mike

  10. Geniusdog

    Mike to me it sounds like your screwed, I guess it just goes to show that you shouldnt mess around unless you know what your doin. I had a similar problem before and I had to do a reinstall, your best bet to keep your files would be to get a knoppix disk and a flash drive** to copy your files to. You will still have to reinstall windows but you will keep all your important data.

    Note
    **The flash drive is not necessary if you have more than one CD burner on your system.

  11. eliminat

    Thank you! Thank you! Thank you! Thank you! Thank you! Thank you!

    You just made my job a lot easier. Migrating files from a customer's old XP machine to a new Vista machine just got a lot simpler.

  12. asdf

    did i ever tell you i love you, you saved me 10 years of my life

  13. kraymah

    there was thsi file that i couldn't delete, i hated to see that file . googled …..file don't delete……and got this site. thanks man……wat else have you got for us?

  14. Peter K

    Beware: "Me too" follows

    The provider of these registry entries should get a medal.

    Here are virtual 2 medals - you deserve one for publishing this.

    !@#$%^& MacroCrap !

  15. clarke

    thank-you very much. why did Vista make file ownership change so difficult?

  16. Bob Cudmore

    This didnt work on my Vista Ultimate. I installed as instructed, but there is no option to 'take ownership' when I right click a file or folder.

  17. Lasse

    This was exactely wat I was looking for some days now ;)
    Thanks, very useful reg fix, now I can get rid of folder and files who I crated on a different PC (so you don`t have the admin rights anymore).

    /Lasse

  18. Steve

    I have the same problem as reported by Bob Cudmore: This didnt work on my Vista Ultimate. I installed as instructed, but there is no option to 'take ownership' when I right click a file or folder.

    I installed, uninstalled and reinstalled with the same result

  19. MIA

    i have installed but.. still cant seem to delete a *MOV file i have on my Vista Pc. when i right click on 'take ownership' it opens up *cmd screen and i cant type anything inside it :(

  20. Emma

    Thank you, thank you, thank you to whoever made this hack!!!! I wanted to copy data across from my old hard drive, and it required over 5 clicks for every single bloody file on the entire hard drive before this hack!

  21. Higham

    Hi Geek,

    Do you know this will work on Windows Vista Home Premium? If so, any help would be much appreciated.

    Yours sincerely,
    Michael Higham

  22. _Ralph_

    I've tried it on Vista Home Premium and can't it to work

  23. Rick

    I already have something as the (Default) item here: HKEY_CLASSES_ROOT\Directory\shell\runas (and in "command" beneath it), so I can't use this mod. (In case anyone's wondering, it's an elevated command prompt.)

    Question: How do you add a second item to that section of the Registry and have them both show up on a right-click?

  24. Nat

    I also couldn't get it to work, any ideas please?

  25. hireger

    Thanks for the posts. I do appreciate the take ownership help. takeownership.zip is GREAT for files/folders. HOWEVER, I need to take ownership of A DRIVE, and neither vista nor this program works.

  26. Fred Stevens

    One of the computers I use is shared, and this feature is very useful; however, I do not want the other users (standard accounts) to see this option. I understand that they will not be able to run the command, since they'll be prompted for an admin password and all, but seeing the option at all is unwanted for mostly aesthetic reasons. The following (if it does not get modified or filtered by this commenting system) is the contents of the .REG file I used:


    Windows Registry Editor Version 5.00

    [HKEY_CURRENT_USER\Software\Classes\*\shell\runas]
    @="Take Ownership"
    "NoWorkingDirectory"=""

    [HKEY_CURRENT_USER\Software\Classes\*\shell\runas\command]
    @="cmd.exe /c takeown /f \"%1\" && icacls \"%1\" /grant administrators:F"
    "IsolatedCommand"="cmd.exe /c takeown /f \"%1\" && icacls \"%1\" /grant administrators:F"

    [HKEY_CURRENT_USER\Software\Classes\Directory\shell\runas]
    @="Take Ownership"
    "NoWorkingDirectory"=""

    [HKEY_CURRENT_USER\Software\Classes\Directory\shell\runas\command]
    @="cmd.exe /c takeown /f \"%1\" /r /d y && icacls \"%1\" /grant administrators:F /t"
    "IsolatedCommand"="cmd.exe /c takeown /f \"%1\" /r /d y && icacls \"%1\" /grant administrators:F /t"

    and the uninstall has been similarly modified:

    Windows Registry Editor Version 5.00

    [-HKEY_CURRENT_USER\Software\Classes]

    [-HKEY_CURRENT_USER\Software\Classes\Directory\shell\runas]

  27. switch

    It would be nice to have this on the Shift+Right Click menu. Just like "Open command window here…" is.
    Anybody know how to do this?

  28. Jym

    5 gold stars for who ever designed this… it works like it was supposed to be there all along, thanks for solving one of the many million anoying things about vista…

  29. Oiler62

    Finally found the quick fix I needed! Thank you!! I'm a novice and learning mre and more each day.
    I upgraded from XP to Vista last week and had some probs loading it, had to re-install again after a glitch. Everything's good but noticed my 120gb HD is almost filled up! I dug deep and saw that Vista created a backup for my entire C drive of my old XP stuff and had another backup with my glitched Vista install. Like 60 GB between them! I managed to delete the old XP crap, but the Vista one was hard. I got bits and pieces of it deleted, tried a shredder program and got a little more, but more times than not that Permission BS popped up. I still had 9gb left to dump. I searched all over the NET for help but was getting mixed results or too complicated. This worked great.
    Thanks again.

  30. iamwoturnot

    You guys would solve all your problems if you'd just join the Linux Revolution and force the evil corporate Microsoft right on out of here ;)

    Never have these kinds of problems in Linux, ever.

  31. Z32Lex

    You've just fixed my biggest Vista annoyance. Thank you, Thank you, Thank you!


Leave a Comment




Leave your friendly comment here. If you have a computer help question, leave it on the forums instead.

Note: Your comment may not show up immediately on the site.

Copyright © 2006-2008 HowToGeek.com. All Rights Reserved.