B
Bob Morvay
This should be simple but I am stuck. I am trying to read all the rows of
my datagrid across all the pages. I can read all the rows on the page that
I am on but I can't seem to figure out how to iterate through all the pages.
Can anyone lend some insight. Here is the basic code that I am using to
attempt to read all the rows...
Private Sub btnUpdate(ByVal sender As System.Object, ByVal e As
System.EventArgs) Handles btnUpdate.Click
Dim item As DataGridItem
For Each item In DataGrid1.Items
ID = Convert.ToInt32(DataGrid1.DataKeys(item.ItemIndex))
UpdateTable()
Next
End Sub
My example datagrid has 3 pages. This code will only update the database
with the items on the page that I am on when I click the update button. I
need it to iterate through all the pages of the datagrid for all the items.
Thanks in advance.
my datagrid across all the pages. I can read all the rows on the page that
I am on but I can't seem to figure out how to iterate through all the pages.
Can anyone lend some insight. Here is the basic code that I am using to
attempt to read all the rows...
Private Sub btnUpdate(ByVal sender As System.Object, ByVal e As
System.EventArgs) Handles btnUpdate.Click
Dim item As DataGridItem
For Each item In DataGrid1.Items
ID = Convert.ToInt32(DataGrid1.DataKeys(item.ItemIndex))
UpdateTable()
Next
End Sub
My example datagrid has 3 pages. This code will only update the database
with the items on the page that I am on when I click the update button. I
need it to iterate through all the pages of the datagrid for all the items.
Thanks in advance.