Role Entity Capabilities

banner art

[Applies to: Microsoft Dynamics CRM 4.0]

Find the latest SDK documentation: CRM 2015 SDK

This entity represents a grouping of security privileges. Users are assigned roles that authorize their access to Microsoft Dynamics CRM.

Note   When you create a new role, you must also add a set of privileges that all roles should have by default. For more information, see Default Privileges Required.

The class for this entity is role. The following table describes the messages for roles, to be used with the Execute method.

Message Description
AddPrivilegesRole Use this message to add a set of existing privileges to an existing role. The privileges are defined by the RolePrivilege class.
AssignUserRolesRole Use this message to assign the specified set of roles to a user.
Create Use this message to create a role.

The information that is used to create the entity instance is specified in the TargetCreateRole class.

You can also call the Create method.

Delete Use this message to delete a role.

The entity instance to delete is specified in the TargetDeleteRole class.

You can also call the Delete method.

RemovePrivilegeRole Use this message to remove a privilege from a role.
RemoveUserRolesRole Use this message to remove the specified user from a role.
ReplacePrivilegesRole Use this message to replace the privilege set of an existing role. This effectively deletes all existing privileges from the role and adds the new specified privileges.
Retrieve Use this message to retrieve a role.

The entity instance to retrieve is specified in the TargetRetrieveRole class.

You can also call the Retrieve method.

RetrieveRolePrivilegesRoleRequest Use this message to retrieve the privileges that are assigned to the specified role.

See Also

Concepts

Other Resources

© 2010 Microsoft Corporation. All rights reserved.