I've another issue with the tree. When a modification is made to values in the leaf nodes I use the the AfterNodeUpdate method to call a recursive function that will calculate the totals further up the tree. i.e. A summary of child totals. The code appears to function fine and I can see that the nodes/cell values are changed as expected. However, when I attempt to commit these modifications to the database I see that many of the rows have a rowstate of unchanged (any that were changed progammatically). But they have changed you can see the values being set as you make changes to the child nodes.I've another simple example of this available athttp://www.smartdata.co.uk/downloads/test_bind_rowstate.zipI noticed that there is a function 'update' available on nodes, but unlike the grid, there isn't global 'updatedata' function.I tried to call Node.Update when setting the values in the recursive function but this has the effect of hiding the changes in the GUI. Very odd indeed!I'm really sorry to ask for more details, but why do these changes not get reflected down to the datasource?
aim123 said:I see that many of the rows have a rowstate of unchanged (any that were changed progammatically).
I did notice that you have the UpdateMode set to 'OnActiveCellChange', and one thing to note about that setting is that it will miss the case where the user leaves the UltraTree control during a cell edit mode session. You might want to use the 'OnActiveCellChangeOrLostFocus' setting instead to avoid that.
Hi Brian, Thank you for taking the time to look at this example.With the original example and assuming that you change the row/cell selection, it will synchronise changes between the tree and the underlying data source. But note that it does this only for the edited row. The issue is that it should notice that all parent rows have also been modified and as such should have a row state of modified. This does not occur. Its as though it only cares about user changes and ignores code changes to cells.Regarding the odd issues with the use of 'Node.Update', using my example simply uncomment the line 'PassedProjectNode.Update()' on line 184. Then when running the test app, on editing a date value and changing focus, the value is wiped as though it is null!
aim123 said:Its as though it only cares about user changes and ignores code changes to cells.
aim123 said:Regarding the odd issues with the use of 'Node.Update', using my example simply uncomment the line 'PassedProjectNode.Update()' on line 184. Then when running the test app, on editing a date value and changing focus, the value is wiped as though it is null!
I've only just updated my tree control to v9.1.20091.2050. is there another release?