Hello all,
I have a form with a group of text/cbo boxes, and two listview controls. I would like to save these textboxes and listviews into a single xml doc with a schema like:
<MyDataFile>
<MyTextboxes>
<TxtBox1>Some Data</TxtBox1>
<TxtBox2>Some Data</TxtBox2>
</MyTextBoxes>
<MyListView1>
<Item1> 'repeat for all n items
<Col1>Some Data</Col1>
<Col2>Some Data</Col2>
</Item1>
</MyListView1>
<MyListView2>
<Item1> 'repeat for all n items
<Col1>Some Data</Col1>
<Col2>Some Data</Col2>
</Item1>
</MyListView2>
</MyDataFile>
I've figured out how to write each of the listview controls to separate xml files using a DataSet and the using the:
as explained here: Know Dot Net - Serializing a ListView to XML
and i think I can figure out how to do the text boxes, but how to I write them all into a single <MyDataFile> document root xml file? If some would give me some hints or a general algorithm to accomplish this it would be greatly appreciated, this is my first foray into vb.net & xml for that matter.
TIA
I have a form with a group of text/cbo boxes, and two listview controls. I would like to save these textboxes and listviews into a single xml doc with a schema like:
<MyDataFile>
<MyTextboxes>
<TxtBox1>Some Data</TxtBox1>
<TxtBox2>Some Data</TxtBox2>
</MyTextBoxes>
<MyListView1>
<Item1> 'repeat for all n items
<Col1>Some Data</Col1>
<Col2>Some Data</Col2>
</Item1>
</MyListView1>
<MyListView2>
<Item1> 'repeat for all n items
<Col1>Some Data</Col1>
<Col2>Some Data</Col2>
</Item1>
</MyListView2>
</MyDataFile>
I've figured out how to write each of the listview controls to separate xml files using a DataSet and the using the:
VB.NET:
DataSet.WriteXml("C:\MyListView.xml")
and i think I can figure out how to do the text boxes, but how to I write them all into a single <MyDataFile> document root xml file? If some would give me some hints or a general algorithm to accomplish this it would be greatly appreciated, this is my first foray into vb.net & xml for that matter.
TIA