1.    11 Apr 2016 #1
    Join Date : Apr 2014
    Space coast of Florida
    Posts : 5,369
    Windows 10 Pro X64 16299.19

    Who owns this - an easy way to see who owns a file or folder.


    information   Information
    dir /q in a Command Prompt window will show you who the owner of a file or folder is. The following is my way of automating this so I can use it easily as often as I want.

    Add Who owns this to the Windows Explorer/File Explore/This PC right click Context Menu. When used it will show you who the current owner of a file or folder (and subfolders) is.

    Step 1:
    Create whoOwns.bat.
    Click Start, type notepad and press Enter.
    Copy and paste the following RED line into the Notepad window:

    dir /q %* > %temp%\whoOwnsRes.txt & notepad %temp%\whoOwnsRes.txt & del %temp%\whoOwnsRes.txt & exit

    Save the files as whoOwns.bat in a folder you will be keeping. Enclose the name in double quotes or set the Save as type to All files (*) to prevent Notepad from adding .txt to the end.

    Step 2:
    Create AddwhoOwns.reg as follows:

    Click Start, type notepad and press Enter.
    Copy and paste the following RED lines into the Notepad window:

    Windows Registry Editor Version 5.00

    Windows Registry Editor Version 5.00

    [HKEY_CLASSES_ROOT\*\shell\whoOwns]
    @="Who owns this"

    [HKEY_CLASSES_ROOT\*\shell\whoOwns\command]
    @=""C:\\xxxxxxxx\\whoOwns.bat" "%1""

    [HKEY_CLASSES_ROOT\Folder\shell\whoOwns]
    @="Who owns this"

    [HKEY_CLASSES_ROOT\Folder\shell\whoOwns\Command]
    @=""C:\\xxxxxxxx\\whoOwns.bat" "%1""

    Note: Change xxxxxxxx to the folder you put whoOwns.bat in.

    Save the file as AddwhoOwns.reg in a folder you will be keeping. Enclose the name in double quotes or set the Save as type to All files (*) to prevent Notepad from adding .txt to the end.

    Step 3:
    Merge AddwhoOwns.reg into you registry by double clicking on it or right clicking and select Merge.

    To use, open Windows Explorer/File Explore/This PC and navigate to the file or folder you are interested in.
    Right click on it and select Who owns this.

    A Command Prompt and a Notepad window will open with the results in file %temp%\whoOwnsRes.txt.
    When you close the Notepad window the %temp%\whoOwnsRes.txt file will be deleted and the Command Prompt window will close.

    For instance, if I do this for a folder like C:\Program Files, I get the following:
    Code:
    Volume in drive C is Lenovo_C
     Volume Serial Number is FC29-1F8F
    
     Directory of C:\Program Files
    
    03/19/2016  11:18 AM    <DIR>          NT SERVICE\TrustedInsta.
    03/19/2016  11:18 AM    <DIR>          NT SERVICE\TrustedInsta..
    03/03/2016  10:00 PM    <DIR>          BUILTIN\Administrators 7-Zip
    02/15/2016  03:12 PM    <DIR>          BUILTIN\Administrators CCleaner
    10/30/2015  03:24 AM    <DIR>          NT SERVICE\TrustedInstaCommon Files
    02/15/2016  02:33 PM    <DIR>          BUILTIN\Administrators Everything
    02/15/2016  07:18 PM    <DIR>          BUILTIN\Administrators Greenshot
    03/10/2016  12:19 PM    <DIR>          NT SERVICE\TrustedInstaInternet Explorer
    02/15/2016  05:35 PM    <DIR>          NT AUTHORITY\SYSTEM    Macrium
    02/15/2016  03:51 PM    <DIR>          BUILTIN\Administrators Malwarebytes
    02/20/2016  12:39 AM    <DIR>          BUILTIN\Administrators Microsoft Games
    02/15/2016  11:11 AM    <DIR>          NT AUTHORITY\SYSTEM    Microsoft LifeCam
    02/15/2016  12:57 PM    <DIR>          NT AUTHORITY\SYSTEM    Microsoft Office
    02/16/2016  11:04 PM    <DIR>          BUILTIN\Administrators MirrorFolder
    02/15/2016  08:01 PM    <DIR>          BUILTIN\Administrators Mozilla Firefox
    02/15/2016  07:50 PM    <DIR>          NT AUTHORITY\SYSTEM    MSBuild
    02/15/2016  11:11 AM    <DIR>          NT AUTHORITY\SYSTEM    NVIDIA Corporation
    02/15/2016  03:07 PM    <DIR>          BUILTIN\Administrators ooRexx
    02/17/2016  09:31 PM    <DIR>          NT AUTHORITY\SYSTEM    Oracle
    02/27/2016  09:11 PM    <DIR>          BUILTIN\Administrators Pale Moon
    02/15/2016  11:07 AM    <DIR>          NT AUTHORITY\SYSTEM    Realtek
    02/15/2016  07:50 PM    <DIR>          NT SERVICE\TrustedInstaReference Assemblies
    02/15/2016  03:57 PM    <DIR>          BUILTIN\Administrators Unlocker
    03/19/2016  11:16 AM    <DIR>          BUILTIN\Administrators VS Revo Group
    10/30/2015  05:02 AM    <DIR>          NT SERVICE\TrustedInstaWindows Defender
    03/02/2016  12:11 PM    <DIR>          NT SERVICE\TrustedInstaWindows Journal
    10/30/2015  05:02 AM    <DIR>          NT SERVICE\TrustedInstaWindows Mail
    03/10/2016  12:19 PM    <DIR>          NT SERVICE\TrustedInstaWindows Media Player
    03/10/2016  12:19 PM    <DIR>          NT SERVICE\TrustedInstaWindows Multimedia Platform
    10/30/2015  03:24 AM    <DIR>          NT SERVICE\TrustedInstaWindows NT
    10/30/2015  05:02 AM    <DIR>          NT SERVICE\TrustedInstaWindows Photo Viewer
    03/10/2016  12:19 PM    <DIR>          NT SERVICE\TrustedInstaWindows Portable Devices
                   0 File(s)              0 bytes
                  32 Dir(s)  140,497,846,272 bytes free
    When I do this for a file like C:\Users\rrkurtz\Documents\Ascenion Fall Festival.zdl, I get:
    Code:
     Volume in drive C is Lenovo_C
     Volume Serial Number is FC29-1F8F
    
     Directory of C:\Users\rrkurtz\Documents
    
    11/10/2006  08:17 PM        30,353,408 DESKTOP\rrkurtz        Ascenion Fall Festival.zdl
                   1 File(s)     30,353,408 bytes
                   0 Dir(s)  140,502,347,776 bytes free
      My ComputersSystem Spec
  2.    12 Apr 2016 #2
    Join Date : Jul 2014
    San Jose, California
    Posts : 2,194
    Ubuntu14.04x64 MintMate17x64 Win10Prox64

    How about adding the "Owner" column to file explorer:

    Click image for larger version. 

Name:	a.jpg 
Views:	4 
Size:	512.3 KB 
ID:	74406
      My ComputerSystem Spec
  3.    13 Apr 2016 #3
    Join Date : Apr 2014
    Space coast of Florida
    Posts : 5,369
    Windows 10 Pro X64 16299.19
    Thread Starter

    That's good too (actually it's excellent) but not as much fun.

    Thanks for the tip though.
      My ComputersSystem Spec
  4.    17 Apr 2016 #4
    Join Date : Feb 2016
    Posts : 14
    Windows 10 Pro 1607

    the "Owner" column doesnt appear in the immediate context menu for the columns in any folder except ones that i went to "more" with and already enabled, do you have a good explanation for either getting all folders viewed through file explorer window to have the column or to get that option to be sticky within the context menu's suggested columns? As its a little meticulous to go to every folder and navigate to the owner option for them the way i seem to be doing it.

    Just thinking that is a great feature when combined with the registry edit that adds the "take ownership" option to files/folders context menus.
      My ComputerSystem Spec
  5.    18 Apr 2016 #5
    Join Date : Apr 2014
    Space coast of Florida
    Posts : 5,369
    Windows 10 Pro X64 16299.19
    Thread Starter

    In File Explorer, with the Owner column showing, click on View then Options at far right, then Change folder and search options.
    Click on the View tab then Apply to all folders. That makes it universal for me.
      My ComputersSystem Spec

 


Similar Threads
Thread Forum
RE: SYSTEM owns User folder on drive D
Re-Post Folks: I recently installed Win10 on a C SSD and set a D hard drive for my data. I have assigned default save to be D. FYI, I do have a C:\User\\Documents, Pictures, etc. also. However, I found that on my drive D, there is a...
User Accounts and Family Safety
RE: SYSTEM owns User folder on drive D
Folks: I recently installed Win10 on a C SSD and set a D hard drive for my data. I have assigned default save to be D. FYI, I do have a C:\User\\Documents, Pictures, etc. also. However, I found that on my drive D, there is a D:\\Documents,...
Network and Sharing
create a new folder or copy a file to a specific folder it doesn't a
Hi everyone, It seem my windows 10 Home having problem, a simple malfunction which I don't understand why this happening, the problem related to each time I create a new folder or copy a file to a specific folder it doesn't appear until press...
General Support
Anyone Owns Asus Eeebook x250ta & Upgraded to Windows 10?
Hi there, So i was planning to Buy this Asus x250ta laptop as i find it tempting, Cheap and perfect for daily use. I most of the time Surf and don't need Storage space so with this laptop with battery life of almost 12hrs and 32gb eMMC, i think...
General Support
General Tips Zip a File or Folder in Windows 10
How to ZIP (compress) a File or Folder in Windows 10 Compressed (zipped) files and/or folders take up less storage space and can be transferred to other computers more quickly than uncompressed files, they can also - in some cases - allow you...
Tutorials
Our Sites
Site Links
About Us
Windows 10 Forums is an independent web site and has not been authorized, sponsored, or otherwise approved by Microsoft Corporation. "Windows 10" and related materials are trademarks of Microsoft Corp.

Designer Media Ltd
All times are GMT -5. The time now is 11:27.
Find Us
Twitter Facebook Google+ Ten Forums iOS App Ten Forums Android App



Windows 10 Forums