CardRequestWindow

This function allocates a window within system memory used to access PC Card memory or I/O space. The window must be mapped by the CardMapWindow function before the window can access the PC Card.

CARD_WINDOW_HANDLE CardRequestWindow(
  CARD_CLIENT_HANDLE hCardClient,
  PCARD_WINDOW_PARMS pCardWinParms 
);

Parameters

Return Values

A driver handle indicates success. NULL indicates failure, and GetLastError returns one of the following values:

  • CERR_BAD_ARGS
    Indicates that the pointer specified for pCardWinParms is not valid.
  • CERR_BAD_HANDLE
    Indicates that hCardClient is not a valid client.
  • CERR_BAD_SOCKET
    Indicates that the socket identifier specified for the hSocket member for CARD_WINDOW_PARMS is not valid or that no PC Card is inserted.
  • CERR_OUT_OF_RESOURCE
    Indicates that card services is unable to allocate memory to track the memory window or that the system has no windows available that match the requested window attributes.

Remarks

This function allocates a memory or an I/O window, according to the values specified in CARD_WINDOW_PARMS. You can use the returned handle for subsequent calls to the CardMapWindow and CardModifyWindow functions.

Requirements

OS Versions: Windows CE 1.0 and later.
Header: Cardserv.h.
Link Library: Cardserv.lib.

See Also

CardMapWindow | CardModifyWindow | CardReleaseWindow | CARD_WINDOW_PARMS

 Last updated on Tuesday, May 18, 2004

© 1992-2003 Microsoft Corporation. All rights reserved.