SCardCancel

The SCardCancel function terminates all outstanding actions within a specific resource manager context.

The only requests that you can cancel are those that require waiting for external action by the smart card or user. Any such outstanding action requests will terminate with a status indication that the action was canceled. This is especially useful to force outstanding SCardGetStatusChange calls to terminate.

LONG SCardCancel(
  IN SCARDCONTEXT hContext  
);
 

Parameters

hContext
Supplies the handle that identifies the resource manager context. The resource manager context is set by a previous call to SCardEstablishContext.

Return Values

If the function… The return value is…
Succeeds SCARD_S_SUCCESS.
Fails An error code (see Error Codes for a list of all error codes).

Remarks

SCardCancel is a smart card tracking function. For a description of other tracking functions, see Smart Card Tracking Functions.

QuickInfo

  Windows NT: Use version 4.0 SP3 and later.
  Windows: Use Windows 95 OSR2.1.
  Windows CE: Unsupported.
  Header: Declared in winscard.h.
  Import Library: Link with winscard.lib.

See Also

SCardEstablishContext, SCardGetStatusChange, SCardLocateCards