T
tshad
I have a datatable that I am using to fill from my dataset to bind to 5
datagrids.
The problem is that the pointers seem to get messed up.
I am looping through the dataset and add records manually until my Category
field changes.
I then bind it to my first DataGrid.
Then I do a dt.Clear()
I then continue looping through my dataset and add more records. But when I
bind it to the next Datagrid, I find that it returned 2 of the same record
and the 4th one is missing.
I then clear the table again (dt.Clear()) and continue.
This time I find the 1st record at the beginning of the table and the end
with one of the other records missing. It is always the correct number of
records, but what happens is that one of the records will be pointed at
twice and one of the records will not be there.
What is causing this problem?
What I am going to have to do to solve the problem is just create 5
different datatables and just change from table to table for each datagrid.
I hope this solves the problem.
Thanks,
Tom
datagrids.
The problem is that the pointers seem to get messed up.
I am looping through the dataset and add records manually until my Category
field changes.
I then bind it to my first DataGrid.
Then I do a dt.Clear()
I then continue looping through my dataset and add more records. But when I
bind it to the next Datagrid, I find that it returned 2 of the same record
and the 4th one is missing.
I then clear the table again (dt.Clear()) and continue.
This time I find the 1st record at the beginning of the table and the end
with one of the other records missing. It is always the correct number of
records, but what happens is that one of the records will be pointed at
twice and one of the records will not be there.
What is causing this problem?
What I am going to have to do to solve the problem is just create 5
different datatables and just change from table to table for each datagrid.
I hope this solves the problem.
Thanks,
Tom