MSXML2.ServerXMLHTTP yielding unrecognized response

MSXML2.ServerXMLHTTP yielding unrecognized response

Post by deathtospa » Wed, 21 Dec 2005 23:45:38


'm using a VBScript/ASP page to submit a request to a (JSP) page on a
remote server, using "MSXML2.ServerXMLHTTP". Here's the main code I'm
using:

================================
...

Set oXmlServerHttp = Server.CreateObject("MSXML2.ServerXMLHTTP.3.0")
Call oXmlServerHttp.SetTimeouts(10000, 10000, 10000, 10000)
Call oXmlServerHttp.Open("GET", sRequestURL, True, Null, Null)
Call oXmlServerHttp.Send()

bResponseReceived = False
If (oXmlServerHttp.ReadyState = 4) Then
bResponseReceived = True
Else
bResponseReceived = oXmlServerHttp.WaitForResponse(30)
End If

...
================================

When I try to submit the call, I get the following error: "The server
returned an invalid or unrecognized response". The script is failing
on the line "bResponseReceived = oXmlServerHttp.WaitForResponse(30)" --
does anybody have an idea on why it is failing, and a possible solution?
 
 
 

MSXML2.ServerXMLHTTP yielding unrecognized response

Post by Brian Staf » Thu, 22 Dec 2005 01:37:29

With an ASYNC call, I think you need to look at priming a callback function.

Maybe try a NON-ASYNC call and loop waiting for a "4" ReadyState.

Brian

 
 
 

MSXML2.ServerXMLHTTP yielding unrecognized response

Post by deathtospa » Thu, 22 Dec 2005 04:31:37

If you're doing a non-asynchronous call, it waits until
oXmlServerHttp.Send() finishes before it returns a result -- which
means you won't need a loop to poll the ReadyState value. And it still
returns the same error message.....


-= Tek Boy =-
 
 
 

MSXML2.ServerXMLHTTP yielding unrecognized response

Post by Brian Staf » Thu, 22 Dec 2005 06:02:43

> If you're doing a non-asynchronous call, it waits until

you're right...my bad!