Grid.SelectionModen doesn't work correctly when use beforerowcolchange event!

Posted by: samo3889 on 9 January 2018, 10:52 pm EST

    • Post Options:
    • Link

    Posted 9 January 2018, 10:52 pm EST

    hi all

    i use C1FlexGridClassic

    when i use BeforeRowColChange event and write e.cancel in event

    then c1FlexGridClassic1.SelectionMode doesn’t work correctly

    I want them both (e.cancel and .SelectionMode = SelModeSettings.flexSelectionFree)

    how i can do that?

    look at the following example : flexSelectionFree.zip

    flexSelectionFree.zip

  • Posted 10 January 2018, 5:32 am EST

    Hi,

    Thank you for sharing the application.

    Setting e.Cancel to True in BeforeRowColChange event, cancels the cell change even before a selection is made and hence the new selected cell does not gets selected. For getting your desired behavior, you may use AfterRowColChange event and set e.Cancel to True inside this event.

    However, I also understand that it might affect any checks that you wish to apply at the time of cell change, therefore could you please share your use case of using these events and what you wish to do.

    Thanks,

    Ruchir Agarwal

  • Posted 13 January 2018, 9:38 pm EST

    hi Ruchir Agarwal

    i try to set e.cancel in AfterRowColChange but it didn’t work ,the same behavior

    yes if i remove e.cancel it’s will affect on checks more than row in grid.

    so There are any suggestions how can I Do That?

    if you want i can create simple example.

    thanks.

    Saleem J

  • Posted 14 January 2018, 6:35 pm EST

    Hello Saleem,

    Setting just SelectionMode to SelModeSettings.flexSelectionFree and setting e.Cancel to True in AfterRowColChange event works at my end. See attached movie.

    The behavior might however be different at your end depending on how and what other things you are implementing. So, could you please modify the attached application to replicate the scenario. Also, it would be great if you could share a video showing exactly what you need.

    Thanks,

    Ruchir Agarwal

    C1FlexGridClassic_Selection.zip

Need extra support?

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

Learn More

Forum Channels