Using VBA in Microsoft Access, I am sending XML to a server to get a response string. It works fine in Windows 7. Recently, some users have upgraded to Windows 10, and this no longers works (all users on Office 16). The specific error is: -2147012867 - A connection with the server could not be established.
The error occurs on the xsite.send line
Here is the code:
Dim xsite As ServerXMLHTTP60
Set xsite = New ServerXMLHTTP60
On Error Resume Next
xsite.setTimeouts 0, 60000, 30000, 600000
xsite.Open "POST", pServerURL & func, False
aErr = Array(Err.Number, Err.Description)
On Error GoTo 0
If 0 = aErr(0) Then 'No error creating the link
xsite.setRequestHeader "Content-Type", "application/x-www-form-urlencoded"
'Set request header with Base64-encoded username/password
xsite.setRequestHeader "Authorization", "Basic " & EncodeBase64(UserName & ":" & Password)
On Error Resume Next
xsite.send "xmlData=" & URLEncode(xmldata)
aErr = Array(Err.Number, Err.Description)
On Error GoTo 0
Debug.Print aErr(0)
Debug.Print aErr(1)
End If
Any ideas?