Treeview problem (row.Table.DataSet.RejectChanges() )


Iam a novice in Windows programming. I have a Windows.Form.Treeview that populates from the database. I also have a reject changes button in the form which basically executes this code

row = (DataRow)tvAccountHierarchy.Nodes[0].Tag;
LoadTree(tvAccountHierarchy, row.Table.DataSet);

I have noticed that when I click on the reject changes button the tree view basically repopulates from the already created Dataset (after rejecting the changes) , but it dosent seem to be re-populating it properly.

The parent - child relationships which show up when loaded the first time (when the form opens up) , does not maintain after i hit the reject changes button.

The code has been moslty borrowed from this link

I am desperately hoping for some help.


P.S: I even tried re-loading the data from the database when i hit the reject button. But still the parent -child relationship seems to get screwed up.
Sign In or Register to comment.

Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!