I can successfully use the code below to import data from an XML file into a DataGridView, but now I need to be able to write the same data back out to XML.
Dim xmlDatadoc As XmlDataDocument = New XmlDataDocument()
xmlDatadoc.DataSet.ReadXml(OpenFD.FileName)
Dim ds As DataSet = New DataSet("Version DataSet")
ds = xmlDatadoc.DataSetDataGridView1.DataSource = ds.DefaultViewManager
DataGridView1.DataMember = "Version"
Can I use something like:
xmlDatadoc.DataSet.Writexml(OpenFD.FileName)
I'm thinking there's some sort of reverse way to do this, but I'm completely stuck. Basically, I need to store records of file versions (VerID = 1, 2, 3...20) into a DataGrid, edit it, and then save it back in the same format. Let me know if you need more info, I'm a beginner here.
Dim xmlDatadoc As XmlDataDocument = New XmlDataDocument()
xmlDatadoc.DataSet.ReadXml(OpenFD.FileName)
Dim ds As DataSet = New DataSet("Version DataSet")
ds = xmlDatadoc.DataSetDataGridView1.DataSource = ds.DefaultViewManager
DataGridView1.DataMember = "Version"
Can I use something like:
xmlDatadoc.DataSet.Writexml(OpenFD.FileName)
I'm thinking there's some sort of reverse way to do this, but I'm completely stuck. Basically, I need to store records of file versions (VerID = 1, 2, 3...20) into a DataGrid, edit it, and then save it back in the same format. Let me know if you need more info, I'm a beginner here.