Scoped XMLDocument2 - parseXML(String xmlDoc)

Parses the XML string and loads it into the XMLDocument2 object.

Table 1. Parameters
Name Type Description
xmlDoc String The document to parse.
Table 2. Returns
Type Description
void

This example parses the xmlString and loads it into the xmlDocument2 object.

var xmlString = "<test>" +
                "  <one>" +
                "    <two att=\"xxx\">abcd1234</two>" +
                "    <three boo=\"yah\" att=\"yyy\">1234abcd</three>" +
                "    <two>another</two>" +
                "  </one>" +
                "  <number>1234</number>" +
                "</test>";
var xmlDoc = new XMLDocument2();
xmlDoc.parseXML(xmlString); 
var rootNode = xmlDoc.getDocumentElement();

Output: