RetrieveTeamPrivilegesRequest RetrieveTeamPrivilegesRequest RetrieveTeamPrivilegesRequest RetrieveTeamPrivilegesRequest Class

Definition

Contains the data that is needed to retrieve the privileges for a team.

For the Web API use the RetrieveTeamPrivileges Function.

public ref class RetrieveTeamPrivilegesRequest sealed : Microsoft::Xrm::Sdk::OrganizationRequest
[System.Runtime.Serialization.DataContract(Namespace="http://schemas.microsoft.com/crm/2011/Contracts")]
public sealed class RetrieveTeamPrivilegesRequest : Microsoft.Xrm.Sdk.OrganizationRequest
type RetrieveTeamPrivilegesRequest = class
    inherit OrganizationRequest
Public NotInheritable Class RetrieveTeamPrivilegesRequest
Inherits OrganizationRequest
Inheritance
RetrieveTeamPrivilegesRequestRetrieveTeamPrivilegesRequestRetrieveTeamPrivilegesRequestRetrieveTeamPrivilegesRequest
Attributes

Examples


      ' It takes some time for the privileges to propagate to the team. Delay the
      ' application until the privilege has been assigned.
      Dim teamLacksPrivilege As Boolean = True
      Do While teamLacksPrivilege
      Dim retrieveTeamPrivilegesRequest As RetrieveTeamPrivilegesRequest = _
      New RetrieveTeamPrivilegesRequest With {.TeamId = _teamId}
    Dim retrieveTeamPrivilegesResponse As RetrieveTeamPrivilegesResponse = _
        CType(svc.Execute(retrieveTeamPrivilegesRequest), RetrieveTeamPrivilegesResponse)
      For Each rp As RolePrivilege In retrieveTeamPrivilegesResponse.RolePrivileges
        If rp.PrivilegeId = readAccountPrivilege.Id Then
            teamLacksPrivilege = False
            Exit For
        Else
            System.Threading.Thread.CurrentThread.Join(500)
        End If
    Next rp
Loop

The following example shows how to use this message. For this sample to work correctly, you must be connected to the server to get an IOrganizationService interface. For the complete sample, see the link later in this topic.

StrongTypesVB#AssignRecordToTeam3

Remarks

Message Availability

This message works regardless whether the caller is connected to the server or offline.

Usage

Pass an instance of this class to the Execute(OrganizationRequest) method, which returns an instance of the RetrieveTeamPrivilegesResponse class.

Privileges and Access Rights

To perform this action, the caller must have privileges on the Privileges entity and access rights on the specified record in the TeamId property. For a complete list of the required privileges, see RetrieveTeamPrivileges message privileges.

Constructors

RetrieveTeamPrivilegesRequest() RetrieveTeamPrivilegesRequest() RetrieveTeamPrivilegesRequest() RetrieveTeamPrivilegesRequest()

Initializes a new instance of the RetrieveTeamPrivilegesRequest class.

Properties

ExtensionData ExtensionData ExtensionData ExtensionData

Gets or sets the structure that contains extra data. Optional.

(Inherited from OrganizationRequest)
Item[String] Item[String] Item[String] Item[String]

Gets or sets the indexer for the Parameters collection.

(Inherited from OrganizationRequest)
Parameters Parameters Parameters Parameters

Gets or sets the collection of parameters for the request. Required, but is supplied by derived classes.

(Inherited from OrganizationRequest)
RequestId RequestId RequestId RequestId

Gets or sets the ID of an asynchronous operation (system job). Optional.

(Inherited from OrganizationRequest)
RequestName RequestName RequestName RequestName

Gets or sets the name of the request. Required, but is supplied by derived classes.

(Inherited from OrganizationRequest)
TeamId TeamId TeamId TeamId

Gets or sets the team for which you want to retrieve privileges.

Applies to

See also