DataServiceContext.CancelRequest Method

Attempts to cancel the operation that is associated with the supplied IAsyncResult object.

Namespace:  System.Data.Services.Client
Assembly:  Microsoft.Data.Services.Client (in Microsoft.Data.Services.Client.dll)

Syntax

'Declaration
Public Sub CancelRequest ( _
    asyncResult As IAsyncResult _
)
'Usage
Dim instance As DataServiceContext 
Dim asyncResult As IAsyncResult

instance.CancelRequest(asyncResult)
public void CancelRequest(
    IAsyncResult asyncResult
)
public:
void CancelRequest(
    IAsyncResult^ asyncResult
)
member CancelRequest : 
        asyncResult:IAsyncResult -> unit
public function CancelRequest(
    asyncResult : IAsyncResult
)

Parameters

Remarks

The IAsyncResult object passed to the asyncResult parameter is the object returned when an operation is executed asynchronously. For more information, see Asynchronous Operations (WCF Data Services).Until this request is processed, the DataServiceContext instance is not in a predictable state. The DataServiceContext can be safely used when the IsCompleted property of the asyncResult returns a value of true.

See Also

Reference

DataServiceContext Class

System.Data.Services.Client Namespace