Link to home
Start Free TrialLog in
Avatar of Jeff Collins
Jeff CollinsFlag for Australia

asked on

Run-time Error '-2147012889' The Server Name or address could not be resolved

User generated image
Receiving the above message (Run-time Error -2047012889 The Server Name or Address could not be resolved') when using a MSXML2.XMLHTTP60 object to send a POST request to the specified URL.

Any ideas where to look?

NOTE : The code is VB6

I've tried a few things with security etc, but still getting the same response.

The general code is as follows (Note the ApplIcation ID has been replaced with the Generic Note)

   Dim myMSXML As MSXML2.XMLHTTP60
   
    Dim AuthURL As String

    AuthURL = "https://identitysso.betfair.au/api/login"

    Set myMSXML = CreateObject("MSXML2.ServerXMLHTTP")
     
    myMSXML.open "POST", AuthURL, False
    myMSXML.setRequestHeader "Accept", "application/json"
    myMSXML.setRequestHeader "Content-Type", "application/x-www-form-urlencoded"
    myMSXML.setRequestHeader "X-Application", "<Application Code>"
   
    myMSXML.send "userName=" & sUserName & "&password=" & sPassword
Avatar of ste5an
ste5an
Flag of Germany image

Obviously, your system cannot resolve identitysso.betfair.au via DNS. My guess: You're in a company system with "DNS protection". Betting websites are here often blocked.

Check on the command line, what nslookup returns.
ASKER CERTIFIED SOLUTION
Avatar of leakim971
leakim971
Flag of Guadeloupe image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Avatar of Jeff Collins

ASKER

i've sent a support request to betfair in relation to the URL. It's the site as per Betfairs online guides, for Australian customers, but agree, it  doesn't seem to exist. Tried the nslookup as per Ste5an's advise, with various URL's and all barring the betfair one works. I should have an answer from them overnight I would imagine.