Hi all
I have the following simplified XML
<Formats> <Bank id="1" name="AIB"> <Content text = "line1" value="value1"/> <Content text = "line2" value="value2"/> </Bank> <Bank id="2" name="Barclays"> <Content text = "line1" value="value1"/> <Content text = "line2" value="value2"/> <Content text = "line3" value="value3"/> </Bank> </Formats>
With the following code I can iterate through the banks and display their names as follows
goXML = CREATEOBJECT('MSXML2.DomDocument') goXML.Load("Formats.XML") gcolElements = goxml.getElementsByTagName("Bank") For Each element In gcolElements ? element.attributes.item(0).text,element.attributes.item(1).text EndFor
But for each bank I need to iterate through the content entries for that bank and extract the text and value attributes. So far I cannot see how to do it. Any suggestions would be very welcome
Many thanks
Paul Newton