XAsyncCancel
Attempts to cancel an asynchronous call.Syntax
Parameters
asyncBlock _Inout_Type: XAsyncBlock* A pointer to the XAsyncBlock for the asynchronous call.
Return value
Type: voidRemarks
If theXAsyncCancel function is invoked for an asynchronous call that has not yet completed, the XAsyncGetResult, XAsyncGetResultSize, and XAsyncGetStatus functions return E_ABORT and completion of the asynchronous call is signalled. Cancellation may happen synchronously, asynchronously, or not at all, depending on the call being canceled. If a completion callback was specified for the asynchronous call, it is then invoked. For more information about completion callbacks, see XAsyncCompletionRoutine.
If the XAsyncCancel function is invoked for an asynchronous call that has already completed, nothing happens.
Requirements
Header: XAsync.h Library: xgameruntime.lib Supported platforms: Windows, XBOX One family consoles and XBOX Series consolesConceptual documentation
See also
XAsyncCompletionRoutineXAsync Members
Asynchronous Programming Model
