RetrieveRequest Class
Updated: November 29, 2016
Applies To: Dynamics 365 (online), Dynamics 365 (on-premises), Dynamics CRM 2016, Dynamics CRM Online
Contains the data that is needed to retrieve a deployment entity or configuration settings record.
Assembly: Microsoft.Xrm.Sdk.Deployment (in Microsoft.Xrm.Sdk.Deployment.dll)
Microsoft.Xrm.Sdk.Deployment.DeploymentServiceRequest
Microsoft.Xrm.Sdk.Deployment.RetrieveRequest
| Name | Description | |
|---|---|---|
![]() | RetrieveRequest() | Initializes a new instance of the RetrieveRequest class. |
| Name | Description | |
|---|---|---|
![]() | EntityType | Gets or sets the type of deployment entity to be retrieved. |
![]() | ExtensionData | Gets or sets the structure that contains extra data.(Inherited from DeploymentServiceRequest.) |
![]() | InstanceTag | Gets or sets the ID or instance tag of the deployment record to be retrieved. |
| Name | Description | |
|---|---|---|
![]() | Equals(Object) | (Inherited from Object.) |
![]() | Finalize() | (Inherited from Object.) |
![]() | GetHashCode() | (Inherited from Object.) |
![]() | GetType() | (Inherited from Object.) |
![]() | MemberwiseClone() | (Inherited from Object.) |
![]() | ToString() | (Inherited from Object.) |
Pass an instance of this class to the Execute method, which returns an instance of RetrieveResponse.
You can use this message to retrieve any of the valid entity types as specified by the DeploymentEntityType enumeration.
An organization deployment object has five possible states as defined by the OrganizationState enumeration.
You can also use the corresponding Windows PowerShell command for the deployment entity you want to retrieve, for example, Get-CrmOrganization or Get-CrmSetting. For more information, see Administer the deployment using Windows PowerShell.
Note that this is for the Deployment Web service. To retrieve organization data records, use RetrieveRequest.
// By instantiating the DeploymentServiceClient in a using statement you ensure that the client // communication channel is closed and the object is disposed when it goes out of scope. // CustomBinding_IDeploymenService is the name of the configuration setting for the CustomBinding using (DeploymentServiceClient client = new DeploymentServiceClient("CustomBinding_IDeploymentService")) { //The EntityIstanceId class is used to identify the object you want to // retrieve. You have the option of using name or ID. EntityInstanceId id = new EntityInstanceId { Name = "AlpineSkiHouse" }; //Retrieve the organization Organization organization = (Organization)client.Retrieve(DeploymentEntityType.Organization, id); client.Close(); }
Any public static ( Shared in Visual Basic) members of this type are thread safe. Any instance members are not guaranteed to be thread safe.
Microsoft Dynamics 365
© 2016 Microsoft. All rights reserved. Copyright



The following is an example of an Organization class instance serialized to XML: