J
jcoon
All,
I need help understanding how you clear then reload or refresh the grid
view. I'm loading the grid view from a xml that can be edited or added to
then saved back. I think I need to clear then reload the grid to reflect
edits saved back to the xml file. currently if I make and edit to the xml
and post back the data it is not reloaded in the gridview without starting
the routine again. how can reload this data to the gridview.
thank you
john
Private Sub btnReadXML_Click(ByVal sender As System.Object, ByVal e As
System.EventArgs) Handles btnReadXML.Click
DataGridView1.Columns.Clear()
Dim filePath As String
filePath = "C:\xml-write\Airports-Runways-test.xml"
dsAirports.ReadXml(filePath)
With DataGridView1
..DataSource = dsAirports
..DataMember = "Airport"
End With
'DataGridView1.Refresh() 'how to reload xml file after clear
End Sub
I need help understanding how you clear then reload or refresh the grid
view. I'm loading the grid view from a xml that can be edited or added to
then saved back. I think I need to clear then reload the grid to reflect
edits saved back to the xml file. currently if I make and edit to the xml
and post back the data it is not reloaded in the gridview without starting
the routine again. how can reload this data to the gridview.
thank you
john
Private Sub btnReadXML_Click(ByVal sender As System.Object, ByVal e As
System.EventArgs) Handles btnReadXML.Click
DataGridView1.Columns.Clear()
Dim filePath As String
filePath = "C:\xml-write\Airports-Runways-test.xml"
dsAirports.ReadXml(filePath)
With DataGridView1
..DataSource = dsAirports
..DataMember = "Airport"
End With
'DataGridView1.Refresh() 'how to reload xml file after clear
End Sub