DWC_NdCancelAsync

Syntax

#include <dwc.h>

BOOL DWC_NdCancelAsync(void);

Arguments

None.

Return Values

TRUE Successful. Upon completion, the DWC_NdProcess function returns DWC_ND_STATE_ERROR. You can get DWC_ECODE_TYPE_ND_CANCEL by using the DWC_GetLastErrorEx function.
FALSE The function either failed or there was no asynchronous process to be canceled. Use the DWC_GetLastErrorEx function to obtain error information.

Description

Cancels the HTTP process that the download library is currently running.

Cancels processing of the DWC_NdGetFileListNumAsync, DWC_NdGetFileListAsync, and DWC_NdGetFileAsync functions.

When TRUE is returned, upon completion the DWC_NdProcess function returns DWC_ND_STATE_ERROR, and you can obtain DWC_ECODE_TYPE_ND_CANCEL by using the DWC_GetLastErrorEx function.

The function returns FALSE if the cancellation process fails or if there are no asynchronous processes that need to be canceled. You can obtain DWC_ECODE_TYPE_ND_STATE by using the DWC_GetLastErrorEx function.

Note: If cancellation fails, you must wait until the asynchronous function that you tried to cancel completes.

The DWC_NdInitAsync and DWC_NdCleanupAsync functions cannot be canceled. If an attempt is made to cancel either one of these functions, FALSE is always returned. You can obtain DWC_ECODE_TYPE_ND_STATE by using the DWC_GetLastErrorEx function.

See Also

DWC_NdGetFileListNumAsync
DWC_NdGetFileListAsync
DWC_NdGetFileAsync
DWC_GetLastErrorEx

Revision History

1.4.12
Revised the error code descriptions.
1.4.7
Added a description of usage.

CONFIDENTIAL