0

I have, maybe trivial problem, but i could not find any answer on Google due to lack of documentation. I`m sending request from my domain to another, and aiming for web service that returns XML. I do this through this piece of code:

url = "some url aiming at web service"
set xmlhttp = CreateObject("MSXML2.ServerXMLHTTP") 
    xmlhttp.open "GET", url, false 
    xmlhttp.send "" 
    xmlString = xmlhttp.responseText
set xmlhttp = nothing 

When i try to print xmlString it returns complete page. How can i access specific nodes and values?

XML is similar to this:

<grandpa>
   <father>value</father>
   <son>value</son>
</grandpa>

1 Answer 1

2

Try to use responseXML which is a full featured XML DOM where you can leverage selectSingleNode with XPath expression to get the node, e.g

xmlhttp.responseXML.selectSingleNode("//grandpa/father");
Sign up to request clarification or add additional context in comments.

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.