Skip to Content

Take Ownership of Files and Folders in Windows Vista

You may purchased a new hard disk drive and replace your current hard disk drive on your machine. Now, with a USB connector cable, you tried to access your previous hard disk drive, like an external drive, to find that there are some folders with security settings preventing you from accessing them! What should you do?

Fear not, as there is a way via the command line using Windows Command Prompt (CMD) to access these secured folders.

(Learn how you can access secured files and folders via command prompt...)

The fundamental idea is to change the permissions on the files and folders to allow users for access. Hence, to do so, these items (which I will refer to as folders and files) have to inherit permissions of the Administrator of the new operating system.

To do so, this can be done using the Command Line:

  1. Click on the Start Button, find the cmd.exe (Command Prompt) command (likely to be under All Programs>Accessories>Command Prompt).
  2. Right-click on the Command Prompt and select "Run As Administrator".
  3. Use the command line to locate the drive location and folder where you need to change the permission. For example,
    cd e:
    cd myfolder
  4. At the folder, let the Administrator take ownership of the items:
    takeown /F . /R /A /D /Y >NUL
  5. After taking the ownership, assign the user with permission to have full access to these items:
    icacls . /grant THEUSER:(OI)(CI)(F) /L /T /Q

    where THEUSER refers to the new account username on the system.

After assigning to THEUSER, that username would have full access to all the files. Hence, you won't have to worry about going a big fuss of employing an expert to do the job for you. You can simply do it equally well!

TechNet References

Trackback URL for this post:

http://www.neohide.com/trackback/300

Post new comment

The content of this field is kept private and will not be shown publicly.
  • Allowed HTML tags: <a> <em> <strong> <cite> <code> <ul> <ol> <li> <dl> <dt> <dd>
  • Lines and paragraphs break automatically.

More information about formatting options