Skip to content

Rename-CitrixRole

Citrix: Renames an administrator role

param(
	[Parameter(Mandatory = $true)]
	[string]$Name,

	[Parameter(Mandatory = $true)]
	[string]$NewName
)

try {
	Import-Module Citrix.DelegatedAdmin.Admin.V1 -ErrorAction Stop
	Rename-AdminRole -Name $Name -NewName $NewName -ErrorAction Stop
	Write-Output "Successfully renamed role '$Name' to '$NewName'."
} catch {
	Write-Error $_
	exit 1
}

The current name of the role.

The new name for the role.

An interactive directory of PowerShell scripts.