PayPal - The request aborted could not create SSL-TLS connection - Resolved

PayPal - The request aborted could not create SSL-TLS connection - Resolved

To resolve the above issue and the following warning

You must write ContentLength bytes to the request stream before calling [Begin]GetResponse.

Include following

System.Net.ServicePointManager.SecurityProtocol = SecurityProtocolType.Tls12 | SecurityProtocolType.Tls11 | SecurityProtocolType.Tls;

in function

 public string HttpCall(string NvpRequest) //CallNvpServer

The function will look as follows

public string HttpCall(string NvpRequest) //CallNvpServer
        {
            string url = pendpointurl;

            //To Add the credentials from the profile
            string strPost = NvpRequest   "&"   buildCredentialsNVPString();
            strPost = strPost   "&BUTTONSOURCE="   HttpUtility.UrlEncode(BNCode);

            System.Net.ServicePointManager.SecurityProtocol = SecurityProtocolType.Tls12 | SecurityProtocolType.Tls11 | SecurityProtocolType.Tls;

            HttpWebRequest objRequest = (HttpWebRequest)WebRequest.Create(url);
            objRequest.Timeout = Timeout;
            objRequest.Method = "POST";
            objRequest.ContentLength = strPost.Length;

Contact us for any question on this topic

10/17/2018

Request URL Too Large Error PayPal REST API

Click here to Read Complete Article

9/21/2018

PayPal Rest API Supported Country codes

Click here to Read Complete Article

9/21/2018

USA - PayPal state and province codes

Click here to Read Complete Article

9/21/2018

Mexico - PayPal state and province codes

Click here to Read Complete Article

9/21/2018

Indonesia - PayPal state and province codes

Click here to Read Complete Article

Search for any Payment Gateway PayPal , PayTm , BIKE BOT , Tech Help , Tech News

Click here to Contact for any Integration Help

Click here if you wants free ₹51 in bank account NOW!

Now how to make Money Online for Free

India Asian Gold Medals