Logo Search packages:      
Sourcecode: pcsc-lite version File versions  Download package

LONG SCardSetAttrib ( SCARDHANDLE  hCard,
DWORD  dwAttrId,
LPCBYTE  pbAttr,
DWORD  cbAttrLen 
)

This function set an attribute of the IFD Handler.

The list of attributes you can set is dependent on the IFD Handler you are using.

Parameters:
[in] hCard Connection made from SCardConnect.
[in] dwAttrId Identifier for the attribute to set.
[in] pbAttr Pointer to a buffer that receives the attribute.
[in] cbAttrLen Length of the pbAttr buffer in bytes.
Returns:
Error code
Return values:
SCARD_S_SUCCESS Successful.
SCARD_E_NOT_TRANSACTED Data exchange not successful.
Test:
 LONG rv;
 SCARDCONTEXT hContext;
 SCARDHANDLE hCard;
 DWORD dwActiveProtocol;
 unsigned char pbAtr[MAX_ATR_SIZE];
 DWORD dwAtrLen;
 ...
 rv = SCardEstablishContext(SCARD_SCOPE_SYSTEM, NULL, NULL, &hContext);
 rv = SCardConnect(hContext, "Reader X", SCARD_SHARE_SHARED,
                   SCARD_PROTOCOL_RAW &hCard, &dwActiveProtocol);
 rv = SCardSetAttrib(hCard, 0x42000001, "\x12\x34\x56", 3);

Definition at line 1202 of file winscard_scf.c.

Referenced by MSGFunctionDemarshall().

{
      return SCARD_E_NOT_TRANSACTED;
}


Generated by  Doxygen 1.6.0   Back to index