I have an UltraTree (v 7.3) component on a windows form (VS 2005) that is bound to a .NET class with three properties (two string values and a boolean value).
The class structure is as follows:public class TreeHierarchy : List<HierarchyItem>{}public class HierarchyItem{}HierarcyItem contains the three properties Name(string), Type(string), Check(bool); and two methods: public List<HierarchyItem> Child, public void AddChild(HierarchyItem hierarchyItem)
I populate the above classes as follows, and bind them to the ultraTree in the form load event...TreeHierarchy treeHierarchy = new TreeHierarchy();HierarchyItem hi = new HierarchyItem("A", "", true);treeHierarchy.Add(hi);hi.AddChild(new HierarchyItem("the quick brown fox", "Add", false));hi.AddChild(new HierarchyItem("2", "Add", false));
hi = new HierarchyItem("B", "Delete", true);treeHierarchy.Add(hi);hi.AddChild(new HierarchyItem("1", "Delete", false));hi.AddChild(new HierarchyItem("2", "Add", true));
ultraTree1.DataSource = treeHierarchy;
The following is achieved when the ColumnSetGenerated event is fired...The "Type" property is bound to a valueList and displays images (Using the valueList.DisplayStyle = ValueListDisplayStyle.Picture; code).The Check property is shown as a checkbox and is set to AllowCellEdit.Full.
All of the above works perfectly :-)
The problem that I have is that when the status of the checkbox changes the BeforeCheck and AfterCheck are not being fired.
I have played around with the NodeStyle.CheckBoxTriState; and NodeStyle.CheckState; properties... but to no avail :(
If anyone could give me a hand it would be very much appreciated.Thanks
I beleive BeforeCheck and AfterCheck only fire for standard-style nodes with checkboxes, not checkbox cells. I think you need to trap CellChange, instead.
Thanks. That works perfectly