Skip to content

Commit 5e909d7

Browse files
Update takeown.md with new date and parameter details
Updated the date to reflect the latest revision and clarified the syntax for the /u and /d parameters.
1 parent 8af340d commit 5e909d7

File tree

1 file changed

+4
-4
lines changed
  • WindowsServerDocs/administration/windows-commands

1 file changed

+4
-4
lines changed

WindowsServerDocs/administration/windows-commands/takeown.md

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ description: Reference article for the takeown command, which enables an adminis
44
ms.topic: reference
55
ms.author: daknappe
66
author: dknappettmsft
7-
ms.date: 10/16/2017
7+
ms.date: 11/04/2025
88
---
99

1010
# takeown
@@ -14,20 +14,20 @@ Enables an administrator to recover access to a file that previously was denied,
1414
## Syntax
1515

1616
```
17-
takeown [/s <computer> [/u [<domain>]<username> [/p [<password>]]]] /f <filename> [/a] [/r [/d {Y|N}]]
17+
takeown [/s <computer> [/u [<domain>\]<username> [/p [<password>]]]] /f <filename> [/a] [/r [/d {Y|N}]]
1818
```
1919

2020
### Parameters
2121

2222
| Parameter | Description |
2323
|--|--|
2424
| /s `<computer>` | Specifies the name or IP address of a remote computer (do not use backslashes). The default value is the local computer. This parameter applies to all of the files and folders specified in the command. |
25-
| /u `[<domain>]<username>` | Runs the script with the permissions of the specified user account. The default value is system permissions. |
25+
| /u `[<domain>\]<username>` | Runs the script with the permissions of the specified user account. The default value is system permissions. |
2626
| /p `[<[password>]` | Specifies the password of the user account that is specified in the **/u** parameter. |
2727
| /f `<filename>` | Specifies the file name or directory name pattern. You can use the wildcard character `*` when specifying the pattern. You can also use the syntax `<sharename>\<filename>`. |
2828
| /a | Gives ownership to the Administrators group instead of the current user. If you don't specify this option, file ownership is given to the user who is currently logged on to the computer. |
2929
| /r | Performs a recursive operation on all files in the specified directory and subdirectories. |
30-
| /d `{Y| N}` | Suppresses the confirmation prompt that is displayed when the current user does not have the **List Folder** permission on a specified directory, and instead uses the specified default value. Valid values for the **/d** option are:<ul><li>**Y** - Take ownership of the directory. If the user does not have permission to read the contents of the directory, the directory permissions will be **replaced** with permissions granting the user full control.</li><li>**N** - Skip the directory.<p>**NOTE**<br>You must use this option in conjunction with the **/r** option.</li></ul> |
30+
| /d `{Y| N}` | Suppresses the confirmation prompt that is displayed when the current user does not have the **List Folder** and **Read** permissions on a specified directory, and instead uses the specified default value. Valid values for the **/d** option are:<ul><li>**Y** - Take ownership of the directory. The directory permissions are replaced with permission granting the user full control only.</li><li>**N** - Skip the directory.<p>**NOTE**<br>You must use this option in conjunction with the **/r** option.</li></ul> |
3131
| /? | Displays help at the command prompt. |
3232

3333
## Remarks

0 commit comments

Comments
 (0)