CmdID / PowerShell / Cmdlets / Rename
Rename-ItemProperty
Renames a property of an item. PowerShell reference
From the PowerShell reference
13 parameters
Alias rnp
What it does
Renames a property of an item. The Rename-ItemProperty cmdlet changes the name of a specified item property. The value of the property is not changed. For example, you can use Rename-ItemProperty to change the name of a registry entry.
Rename-ItemProperty [-Path] <String> [-Name] <String> [-NewName] <String> [-PassThru] [-Force] [-Filter <String>] [-Include <String[]>] [-Exclude <String[]>] [-Credential <PSCredential>] [-WhatIf] [-Confirm] [-UseTransaction] [<CommonParameters>]Rename-ItemProperty -LiteralPath <String> [-Name] <String> [-NewName] <String> [-PassThru] [-Force] [-Filter <String>] [-Include <String[]>] [-Exclude <String[]>] [-Credential <PSCredential>] [-WhatIf] [-Confirm] [-UseTransaction] [<CommonParameters>]
Rename a registry entry
Rename-ItemProperty -Path HKLM:\Software\SmpApplication -Name config -NewName oldconfigIdentifyIts page in the reference: Rename-ItemProperty.
Parameters
-CredentialSpecifies a user account that has permission to perform this action. The default is the current user.
WARNING: This parameter is not supported by any providers installed with Windows PowerShell.-ExcludeSpecifies items that this cmdlet omits. The value of this parameter qualifies the Path parameter. Enter a path element or pattern, such as "*.txt". Wildcard characters are permitted.-FilterSpecifies a filter in the format or language of the provider. The value of this parameter qualifies the Path parameter.
The syntax of the filter, including the use of wildcard characters, depends on the provider. Filters are more efficient than other parameters, because the provider applies them when the cmdlet gets the objects rather than having PowerShell filter the objects after they are retrieved.-ForceForces the cmdlet to rename a property of an object that cannot otherwise be accessed by the user. Implementation varies from provider to provider. For more information, see about_Providers.-IncludeSpecifies only those items upon which the cmdlet acts, excluding all others. The value of this parameter qualifies the Path parameter. Enter a path element or pattern, such as "*.txt". Wildcard characters are permitted.-LiteralPathSpecifies a path to the item. Unlike the Path parameter, the value of LiteralPath is used exactly as it is typed. No characters are interpreted as wildcards. If the path includes escape characters, enclose it in single quotation marks. Single quotation marks tell PowerShell not to interpret any characters as escape sequences.-NameSpecifies the current name of the property to rename.-NewNameSpecifies the new name for the property.-PassThruReturns an object that represents the item property. By default, this cmdlet does not generate any output.-PathSpecifies a path to the item.-UseTransactionIncludes the command in the active transaction. This parameter is valid only when a transaction is in progress. For more information, see about_Transactions.-ConfirmPrompts you for confirmation before running the cmdlet.-WhatIfShows what would happen if the cmdlet runs. The cmdlet is not run.