Hi All
I am trying to get vb.net to select a single node by id. I then want get all of the childnodes within the id and place them in to textboxes. Please see code below:
Xml doc
<Subject>
<Items>
<Item id="1">
<CustName>john</CustName>
<Filename>
</Filename>
<StartDate>
</StartDate>
<FinishDate>
</FinishDate>
<Cost>
</Cost>
<PayFrequency>
</PayFrequency>
<Type>Video</Type>
<File>c:\test.avi</File>
<Time>6</Time>
<TimeFrom>181</TimeFrom>
</Item>
<Item id="2">
<CustName>
</CustName>
<Filename>...........................................
Vb code
Dim doc As New XmlDocument()
doc.Load(module1.path)
Dim n As XmlNode = doc.SelectSingleNode("/Subject/Items/Item[@ID='1']")
TextBox1.Text = n("CustName").InnerText
Have scoured google and Daniweb forums but cannot find the answer im looking for.
Thanks for your help in advance
John