I have a code in VBA that worked perfectly for a long time. Suddenly it stopped working for no reason. Nothing has changed on my side.
I use it to download web pages and store them in strings like this:
Function something() As String
URL = "www..."
Set XMLHTTP = CreateObject("WinHttp.WinHttpRequest.5.1")
XMLHTTP.Open "GET", URL, False
XMLHTTP.send
something = XMLHTTP.responseText
End Function
at XMLHTTP.send I get the following error: Run-time error '-2147012739 (80072f7d)': An error occurred in the secure channel support
Whats is the meaning of this error and what can be done?
I tried reading about it but it seems that its a generic error and could be many things. Perhaps Microsoft changed some protocols or something similar?
I had this same error: 6/30/2018
I'm running Excel on windows 7,
On a Mac, In Parallels.
This was a very simple fix.
Goto Control Panel,
Click Network and Internet,
Click Network and Sharing Center, (at the Bottom Left CLICK Internet Options)
Internet Properties Dialog Box will come up, Click the Advanced Tab
Scroll to bottom and turn on "Use TLS1.2" (Mine was already Set Prior to receiving the Error) Click Apply
Here is the link to the downloads need for the proper Windows OS Update file: http://www.catalog.update.microsoft.com/search.aspx?q=kb3140245
I downloaded and Installed the UpDate from Windows Explorer (File Manager) Restarted Windows
and ran the VBA. It ran perfectly
Thanks to Srinath Gudimetla see his link is below for full details: https://www.linkedin.com/pulse/working-vba-tls-protocol-srinath-gudimetla
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With