ServiceClient.ExecuteOrganizationRequestAsync Method
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Executes a Dataverse Organization Request (In Async mode) and returns the organization response object. Also adds metrics for logging support.
public System.Threading.Tasks.Task<Microsoft.Xrm.Sdk.OrganizationResponse> ExecuteOrganizationRequestAsync (Microsoft.Xrm.Sdk.OrganizationRequest req, string logMessageTag = "User Defined", bool useWebAPI = false, System.Threading.CancellationToken cancellationToken = default);
member this.ExecuteOrganizationRequestAsync : Microsoft.Xrm.Sdk.OrganizationRequest * string * bool * System.Threading.CancellationToken -> System.Threading.Tasks.Task<Microsoft.Xrm.Sdk.OrganizationResponse>
Public Function ExecuteOrganizationRequestAsync (req As OrganizationRequest, Optional logMessageTag As String = "User Defined", Optional useWebAPI As Boolean = false, Optional cancellationToken As CancellationToken = Nothing) As Task(Of OrganizationResponse)
Parameters
Organization Request to run
- logMessageTag
- String
Message identifying what this request in logging.
- useWebAPI
- Boolean
When True, uses the webAPI to execute the organization Request. This works for only Create at this time.
- cancellationToken
- CancellationToken
Propagates notification that operations should be canceled.
Returns
Result of request or null.