C1FlexGrid: detecting before and after multiple rows edit?

Posted by: hdle on 29 January 2019, 1:52 pm EST

    • Post Options:
    • Link

    Posted 29 January 2019, 1:52 pm EST

    Hi,

    Is there away to detect when a multiple row edit start and complete? The use case is like this, the user can select checkbox in multiple rows/multiple cells and click on it (or press space bar) to check and uncheck it. When this occur, AfterEdit event will trigger for each selected cell.

    The problem is I have an undo/redo implementation that save the operation for redo and I need to group all the cells as a single edit operation. Unfortunately, I have no way of detecting when it starts and end.

    Is there any event to trick to detect when edit start and last edited item is complete?

    Thanks,

    Hai

  • Posted 30 January 2019, 5:32 am EST

    Hi,

    attached is a sample which shows how to detect when the last cell of a multi selection range is toggled, and it reports all affected rows in a messagebox.

    Note: this sample works only if the grid has SelectionMode = ListBox. Otherwise, the code in “BeforeEdit” would have to be changed.

    This workaround was developed a long time ago with the help of C1 support :wink:

    Best regards

    Wolfgang

    FlexMultiCheck.zip

  • Posted 30 January 2019, 8:06 pm EST

    Wolfgang,

    Thanks for your help. I was able to use your example to make what I need to work. Instead of using BeforeEdit (which trigger often without edit activity), I used EditStart event to track the number of checkbox needing to be edited.

    Thanks,

    Hai

Need extra support?

Upgrade your support plan and get personal unlimited phone support with our customer engagement team

Learn More

Forum Channels