HRESULT IsValid(
BSTRbstrFriendname// in
BSTRbstrAcceptTypes// in
long *plResult// out
);
The IsValid function determines whether the instance is valid given the accepted types string. The Payment Manager calls this function to determine whether the specified instance supports any of the payment types listed in the bstrAcceptTypes string. The IsValid function is used by the user interface to indicate whether an instance of a payment type is accepted at a merchant's site. Instances that are not accepted at a merchant's site appear shaded.
This function returns one of the following values.
Value | Meaning |
---|---|
E_FAIL | Failure. |
E_INVALIDARG | One or more of the arguments is invalid. |
S_OK | Success. |
The AcceptedTypes payment information property returns the types of credit-card payment that a merchant accepts for payment. The :clear value assigned to accepted credit card names signifies a clear text representation (no encryption).
This payment information property takes as a parameter bstrTypes, which is a string containing a list of name/value pairs. Note in the following example that the type name (Visa, MasterCard, Amex
) and the encryption value (clear
) are separated by colons:
"Visa:clear;MasterCard:clear;Amex:clear"