ExportSolutionRequest Class

Definition

Contains the data that’s needed to export a solution.

For the Web API use the ExportSolution Action.

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

Examples

 // Export or package a solution
//Export an a solution

     var exportSolutionRequest = new ExportSolutionRequest();
         exportSolutionRequest.Managed = false;
         exportSolutionRequest.SolutionName = solution.UniqueName;

     var exportSolutionResponse = (ExportSolutionResponse)svc.Execute(exportSolutionRequest);
     byte[] exportXml = exportSolutionResponse.ExportSolutionFile;
     string filename = solution.UniqueName + ".zip";
     File.WriteAllBytes(outputDir + filename, exportXml);
     Console.WriteLine("Solution exported to {0}.", outputDir + filename);

Remarks

Message Availability

For this message to work, the caller must be connected to the server.

Usage

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

Privileges and Access Rights

To perform this action, the caller must have privileges listed in ExportSolution message privileges.

Notes for Callers

The properties of this request correspond to the options in the export solution dialog box in the application. The following table describes the settings included with each of the Export* settings.

Member

Setting

Display Name

Description

Constructors

ExportSolutionRequest()

Initializes a new instance of the ExportSolutionRequest class

Properties

ExportAutoNumberingSettings

Gets or sets whether auto numbering settings should be included in the solution being exported. Optional.

ExportCalendarSettings

Gets or sets whether calendar settings should be included in the solution being exported. Optional.

ExportComponentsParams

Gets or sets the set of solution components to export.

ExportCustomizationSettings

Gets or sets whether customization settings should be included in the solution being exported. Optional.

ExportEmailTrackingSettings

Gets or sets whether email tracking settings should be included in the solution being exported. Optional.

ExportExternalApplications

For internal use only.

ExportGeneralSettings

Gets or sets whether general settings should be included in the solution being exported. Optional.

ExportIsvConfig

Gets or sets whether ISV.Config settings should be included in the solution being exported. Optional.

ExportMarketingSettings

Gets or sets whether marketing settings should be included in the solution being exported. Optional.

ExportOutlookSynchronizationSettings

Gets or sets whether outlook synchronization settings should be included in the solution being exported. Optional.

ExportRelationshipRoles

Gets or sets whether relationship role settings should be included in the solution being exported. Optional.

ExportSales

Gets or sets whether sales settings should be included in the solution being exported. Optional.

ExtensionData

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

(Inherited from OrganizationRequest)
Item[String]

Gets or sets the indexer for the Parameters collection.

(Inherited from OrganizationRequest)
Managed

Gets or sets whether the solution should be exported as a managed solution. Required.

Parameters

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

(Inherited from OrganizationRequest)
RequestId

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

(Inherited from OrganizationRequest)
RequestName

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

(Inherited from OrganizationRequest)
SolutionName

Gets or sets the unique name of the solution to be exported. Required.

TargetVersion

Get or set a value indicating the version that the exported solution will support.

Applies to