Remove-SCUserRole

Removes an existing user role.

Description

The Remove-SCUserRole cmdlet removes an existing user role from System Center Virtual Machine Manager (VMM). You can remove the following roles: Delegated Administrator, Read-Only Administrator, or Self-Service User. Howerver, you cannot remove the Administrator role.

For more information about Remove-SCUserRole, type "Get-Help Remove-SCUserRole -online".

Parameters

UserRole

Required? true
Accept Pipeline Input? true (ByValue)
Position? 0
Specifies a user role object.

Confirm

Required? false
Accept Pipeline Input? false
Position? named
Prompts for confirmation before running the command.

JobGroup

Required? false
Accept Pipeline Input? false
Position? named
Specifies an identifier for a series of commands that will run as a set just before the final command that includes the same job group identifier runs. 

JobVariable

Required? false
Accept Pipeline Input? false
Position? named
Specifies that job progress is tracked and stored in the variable named by this parameter. 

PROTipID

Required? false
Accept Pipeline Input? false
Position? named
Specifies the ID of the PRO tip that triggered this action. This allows for auditing of PRO tips.

RunAsynchronously

Required? false
Accept Pipeline Input? false
Position? named
Indicates that the job runs asynchronously so that control returns to the command shell immediately. 

Examples

1: Remove the specified user role.
PS C:\> $UserRole = Get-SCUserRole -Name "ContosoDelegatedAdmin"
PS C:\> Remove-SCUserRole -UserRole $UserRole
The first command gets the user role object named ContosoDelegatedAdmin and stores the object in the $UserRole variable.

The second command removes the "Contoso Admin" user role from the VMM database.

See Also