I'm using the following environment:
The request is successfully built however when I call the following code:
_oTranController = new AuthNetControllers.createTransactionController(apiRequest: _oTranRequest); _oTranController.Execute(); _oResponse = _oTranController.GetApiResponse();
The response object is NULL
I get the exception There was an error generating the XML document
Nothing shows up anywhere else, just that error.
Any help appreciated.
Solved! Go to Solution.
05-24-2020 11:53 AM
Solution founds.
Following fixes:
1. paymentType needed to be the actual creditcard variable not an enumerator type.
_paymentType = new AuthNetContract.paymentType { Item = _creditCardType };
2. The expirationdate was returning 4 digit year instead of 2 digit year.
05-25-2020 11:46 PM
Additional details:
BaseUrl: https://test.authorize.net
CardPresentUrl: https://test.authorize.net
XmlBaseUrl: https://apitest.authorize.net
05-25-2020 02:04 PM
Solution founds.
Following fixes:
1. paymentType needed to be the actual creditcard variable not an enumerator type.
_paymentType = new AuthNetContract.paymentType { Item = _creditCardType };
2. The expirationdate was returning 4 digit year instead of 2 digit year.
05-25-2020 11:46 PM