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
385
Select multiple rows on select drag inside the grid
posted

Hi,

I have a scenario where in the DataGrid after selecting the first row, hold the select click and move mouse over to the next rows so that the next rows will be added to the selection.

Is this possible?

Thanks,

Manikanta Vundavalli

Parents
No Data
Reply
  • 1560
    Offline posted

    Hello,


    I have been looking into your question and what I could say is that by design selecting a range of rows is enabled via the Click + Space combination.
    Changing the default selection behavior should be implemented entirely on application level and could potentially have some side effects on the current implementation.


    I have prepared a small sample in order to demonstrate a possible approach to achieve your requirement. The first step is to disable the selection on row click via the exposed selectRowOnClick property. After that, you should handle the pointerdown, pointerup and mouseover events and implement the required behavior. Also, in order to prevent the default behavior on click, you should cancel the rowSelectionChanging event.


    Here could be found my sample for your reference. However, please keep in mind that overriding the default selection behavior should be implemented entirely on application and could be considered beyond the scope of Infragistics support. The suggested approach is just a simple demonstration, it is not fully tested and could not behave as expected in all scenarios.


    Let me know if I may be of any further assistance.


    Sincerely,
    Teodosia Hristodorova
    Software Developer

Children