I like to use XmlNodeList to load the xml and iterate over the nodes. Here's how:
See if you can use something like this. this way, you can iterate over the xml. Once you are able to do that, you can use if...then statements to filter what you want, and add records to either an array or directly to the control. if you have any specific questions, let me knowCode:Private Sub parseXML() Dim doc As New XmlDocument() Dim i As Integer = 0 Try doc.Load(XmlFile) 'where XmlFile is the path to the file Dim elemList As XmlNodeList = doc.GetElementsByTagName(START_NODE) 'where START_NODE is the top level node in your xml file. For i = 0 To elemList.Count - 1 debug.print( elemList(i).ChildNodes(0).InnerXml) 'first level node debug.print( elemList(i).ChildNodes(1).InnerXml) 'second node Next i Catch ex As Exception Throw End Try End Sub




Reply With Quote