Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

OLE IDispatch exception code 0 from MSXML3.dll 1

Status
Not open for further replies.

vfp4ever

Programmer
Oct 18, 2013
71
East Java
Hello,

until recently I was able to download images from a web site using code like this:

loHttpRequest = CreateObject( "MSXML2.ServerXMLHTTP" )
loHttpRequest.Open( "GET", lcImageAddress, .F. )
loHttpRequest.Send( )
STRTOFILE( loHttpRequest.ResponseBody, lcImageFileName )

Suddenly, while working within the same session, an "OLE IDispatch exception code 0: the connection with the server was terminated abnormally" appeared, and since then I have not been able to make it work again.
The error may change to "... code 0: Access is denied" or "... code 0: Unspecified error" if I try to use a different syntax in CreateObject.

I am using VFP9 SP2 and Firefox on Windows 7 Professional, and step into the same error with a different web browser (specifically as VFP calls the Send method). The images are easily displayed on the browser at their URL address.
At first I thought the msxml3.dll file got corrupted, but using msxml6.dll does not solve the problem.

I suspect it has to do with security certificates, though I have no clue how to proceed.

Dario
 
If i.colnect.net is not willing to respond to requests with certain signatures, that might include IE signatures, may not be the knowledge and decision of that webmaster. But that's a limitation that's quite ridiculous.

If you'd want to solve all requests with the same MSXML based code, that better works where you have the basis for current TLS libraries and certificates. From that perspective you can never know whether your code can be used for anyone on any system in any state. For that to work, you'd have to implement a lot of things, unthinkable.

I think the problem you have is very specific to your own computer only. Edit: When I use agent strings of Curl I also get the error in Win10. So yes, the server i.colnect.net seems very selective about requests. The intention sems to be preventing what you do, crawling the pictures of the site.

Bye, Olaf.

Olaf Doschke Software Engineering
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top