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
2515
How to prevent igGrid row from automatically being deselected
posted

We're using 2016.1. We're also using the igGridSelection event rowSelectionChanging to control whether or not a row gets selected when clicked. This seems to work fine. However, when clicking a different row in the igGrid, the currently selected row is automatically de-selected (even if our code prevents the newly clicked row from being selected). How can we prevent a row from being automatically de-selected when clicked?

Parents
No Data
Reply
  • 3995
    Suggested Answer
    Offline posted

    Hello,

    returning false in rowSelectionChanging will prevent deselecting the previous row and selecting the clicked one.

    For example:

                            rowSelectionChanging: function (e, ui) {
                             if(ui.row.index === 0) {
                               return false;
                              }
                            }


Children