This tip was printed from the MalekTips Computer and Technology Help and Tips website at http://malektips.com.

Windows XP and DOS - Display Directory and File Owners

SUMMARY: If you share your Windows XP machine with others, this parameter lets you display directory and file ownership at the DOS prompt or in a batch file.

If you administer a Windows XP machine containing multiple user accounts, it may prove beneficial to view who owns a particular file or directory. This can help prevent accidentally moving or deleting a file used by someone else, or this feature can help monitor unwanted activity.

dir /q

If you just want to find files owned by the Administrator account, for example, use the following piped command:

dir /q | find "Administrator"

To view all files owned by Administrator in the current directory and all subdirectories, pipe the command with findstr as follows:

dir /q /s | findstr "Administrator Directory"

This will display each directory name followed by all files (if any) owned by the Administrator account.


 

 

Press the "print" button on your browser or select "File" - "Print" to print this tip. Then, return to Windows XP and DOS - Display Directory and File Owners

Standard disclaimer applies - read http://malektips.com/disclaim.html