Add-RDMRoleToUser
Synopsis
Add role to an user
Syntax
NameParams
Add-RDMRoleToUser [-RoleName] <string> [-UserName] <string> [-ForcePromptAnswer <DialogResult[]>]
[<CommonParameters>]ObjectParams2
Add-RDMRoleToUser [-UserObject] <PSUserInfo> [-RoleName] <string>
[-ForcePromptAnswer <DialogResult[]>] [<CommonParameters>]ObjectParams
Add-RDMRoleToUser [-RoleObject] <PSRoleInfo> [-UserObject] <PSUserInfo>
[-ForcePromptAnswer <DialogResult[]>] [<CommonParameters>]NameParams2
Add-RDMRoleToUser [-RoleObject] <PSRoleInfo> [-UserName] <string>
[-ForcePromptAnswer <DialogResult[]>] [<CommonParameters>]Description
Add role to an user
Examples
Add role to an user.
Parameters
-ForcePromptAnswer
Switch to use with caution. It will automatically answer prompt asking yes/no, yes/no/cancel, or ok/cancel questions. In case of multiple prompts, multiple values can be passed to this parameter. Here are the accepted values:
Yes: Accept the prompt. Cover the OK and Automatic value.
No: Refuse the yes/no/cancel prompt. "Cancel" is the fallback option if there is no "No" option.
Cancel: Cancel the yes/no/cancel prompt. "No" is the fallback option if there is no "Cancel" option.
-RoleName
Role name
-RoleObject
Role object, must be retrieved from Get-RDMRole or created via New-RDMRole.
-UserName
User name
-UserObject
User object, must be retrieved from Get-RDMSecurityGroup or created via New-RDMUser.
CommonParameters
This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutBuffer, -OutVariable, -PipelineVariable, -ProgressAction, -Verbose, -WarningAction, and -WarningVariable. For more information, see about_CommonParameters.
Inputs
System.String
The name of the role and/or user
RemoteDesktopManager.PowerShellModule.PSOutputObject.PSRoleInfo
The Role to which the user will be assigned
RemoteDesktopManager.PowerShellModule.PSOutputObject.PSUserInfo
The user to which a role will be assigned
Notes
For more information, type "Get-Help Add-RDMRoleToUser -detailed". For technical information, type "Get-Help Add-RDMRoleToUser -full".
Last updated
Was this helpful?