Export (0) Print
Expand All
DOM
Expand Minimize
0 out of 4 rated this helpful - Rate this topic

responseXML Property (IXMLHTTPRequest)

Represents the parsed response entity body.

var objDispatch = oXMLHttpRequest.responseXML;

Example

var xmlhttp = new ActiveXObject("Msxml2.XMLHTTP.3.0");
xmlhttp.open("GET", "http://localhost/books.xml", false);
xmlhttp.send();
WScript.Echo(xmlhttp.responseXML.xml);


Set objDispatch = oXMLHttpRequest.responseXML
HRESULT get_responseXML(IDispatch** ppBody);

Parameters

ppBody[out, retval]

The response entity body as an XML document.

C/C++ Return Values

S_OK

The value returned if successful.

E_PENDING

The value returned if the data is unavailable.

The property is read-only. For security reasons, the parser validation features are always turned off to prevent Microsoft® XML Core Services (MSXML) from attempting to download a document type definition (DTD) or XML-Data definition. If the response entity body is not valid XML, this property returns DOMDocument that was parsed so that you can access the error. This property does not return IXMLDOMParseError itself, but it is accessible from DOMDocument.

If the response was generated by an Active Server Pages (ASP) page and the Multipurpose Internet Mail Extension (MIME) type was not correctly set to one of the supported MIME types using the ASP method Response.ContentType then responseXML will be empty.

The supported MIME types for MSXML 6.0 are: "text/xml", "application/xml" or anything that ends with "+xml", for example "application/rss+xml".

The supported MIME types for MSXML 3.0 are: "text/xml" and "application/xml".

Implemented in: MSXML 3.0, MSXML 6.0

Did you find this helpful?
(1500 characters remaining)
Thank you for your feedback
Show:
© 2014 Microsoft. All rights reserved.