Determine if a member is an XMLNode or an array of nodes
When an XMLNode contains multiple instances of tags with the same name, then these are represented in the XMLNode tree by the member containing an array of XMLNodes. For example, given the following XML and its XMLNode representation of the price tag:
<?xml version="1.0" encoding="UTF-8"?> <!-- Simple XML to do a test for well-formedness --> <catalog> <book id="book69"> <author>Pomeroy, Steve</author> <title>RPC Manual</title> <price currency="GBP">44.95</price> <price currency="CAD">89.95</price> </book> </catalog>
To determine if a member is an XMLNode use XMLGetNode():
Var1 = Valid(XMLGetNode(XMLNode\catalog\book)); Var2 = Valid(XMLGetNode(XMLNode\catalog\book\price));
Var1 will be set to ‘TRUE’, Var2 will be set to ‘FALSE’.