The underlying connection was closed: Could not establish trust relationship for the SSL/TLS secure channel.
When you try to open WSDL link in any browser, you see this warning message :
In your client code where SOAP request, before consuming web services, use this statement :
C# Solution
ServicePointManager.ServerCertificateValidationCallback = delegate { return true; };
VB.NET Solution
Dim delCert = Function() Return True
ServicePointManager.ServerCertificateValidationCallback = delCert
Note: Don't forget to add following namespaces :
System.Net
System.Net.Security
System.Security.Cryptography.X509Certificates
If you check the statement, anonymous method always returns true. This means, accept all certificate regardless of their authorization.