Your Privacy Matters: We use our own and third-party cookies to improve your experience on our website. By continuing to use the website we understand that you accept their use. Cookie Policy
20
Wintree UltraTreeColumnSet cell clicked event
posted

Hi,

I have an Ultrtree control I want to show in outlook express view style. I added few columns, one of which is a checked/unchecked column for selecting rows in the tree.

I managed to get the column to show a checkbox ( AllowCellEdit = AllowCellEdit.Full, DataType = typeof(bool)) but I can't find a way to get an event of the checked state change. how can I achieve that?

what I need to do is to check/uncheck all the node's children, so value change event is not good as it is recursively called from the children.

I tried using before/after edit mode but is not called all the time...(I think it depends on the node selected or not...)

is there a way I can add a checkbox control to a cell in another way than the inherent way (described above)?

is there a way to catch events from the displayed checkbox?

thanks,

Lior

Parents
No Data
Reply
  • 21795
    Offline posted

    Hello Yossi,

    Please find bellow answers to your questions:

    • is there a way I can add a checkbox control to a cell in another way than the inherent way – yes, you can make the cell to show checkbox by setting its EditorComponent to UltraCheckEditror. This way you will not need to set AllowCellEdit to Full, nor you need to set the DataType to bool.
    • is there a way to catch events from the displayed checkbox – the event you need to handle is exactly CellValueChanged. Get the new value of the cell form CurrentValue property of the event arguments and assign this value to all child nodes.

    I’ve implemented this in the attached sample project and CellValueChanged does not fire for child nodes in my sample. This is expected behavior as this event fires only when the value is changed during an edit mode session and do not fire when it is changed through code.

    Please check my sample and let me know if you have any additional questions.

    UltraTreeCheckBoxes.zip
Children
No Data