Loop over a generic XML file
I have an xml file that I need to loop over. The xml.bld example shows how to loop on attributes of a node. I need to loop on the contents of sub nodes. For example:
<dependencies>
<component>
<name>ProjA</name>
<version>1.2.3</version>
</component>
<component>
<name>ProjB</name>
<version>2.3.4</version>
</component>
</dependencies>
Is there a simple way to set this up and loop on each component and retrieve it's cooresponding version number?
Thanks
Tom
|