Reasonable setting of CurrentRow after delete of selected rows

4 posts, 0 answers
  1. erwin
    erwin avatar
    358 posts
    Member since:
    Dec 2006

    Posted 04 Sep 2009 Link to this post


    What's a good strategy to make the grid more user friendly in the following situation:

    The grid allows for multiple selection of rows and the user can delete selected rows.
    Per default, if the selection includes the current row, and the data is reloaded, the current row is reset to the first row of the datasource.
    This can be a bit confusing, especially if the user has set custom sorting differently from the orignial sort order of the dataset.

    I would like to have the current row after the reload set to either the row immediately preceeding or following the previously selected (and now deleted) rows. That is, the grid should not, or only minimally scroll the contents.

    A proposed solution should work regardless of the data that is loaded into the datasource. The code should not have to know the logical ID column of the rows.

    Any suggestions?

    Regards
    erwin

  2. Jack
    Admin
    Jack avatar
    2333 posts

    Posted 07 Sep 2009 Link to this post

    Hello erwin,

    Thank you for this suggestion. We have it in mind and we will change the grid behavior in our future versions accordingly. Unfortunately, there is no work around for this issue. If you have more questions, don't hesitate to ask.

    Best wishes,
    Jack
    the Telerik team

    Instantly find answers to your questions on the new Telerik Support Portal.
    Watch a video on how to optimize your support resource searches and check out more tips on the blogs.
  3. UI for WinForms is Visual Studio 2017 Ready
  4. erwin
    erwin avatar
    358 posts
    Member since:
    Dec 2006

    Posted 07 Sep 2009 Link to this post

    Jack, thanks for the response.
    I was not necessarily suggesting that the grid would implement this but was asking about how to implement it myself.

    I currently have a workaround, but that relies on knowledge of the data source. (I store the value of an ID Column of the row that I would like to be current after the reload).

    I would like to make that more general, but have to find a way to locate a logical row in the grid after a reload of the data source.

    Regards
    Erwin

  5. Jack
    Admin
    Jack avatar
    2333 posts

    Posted 08 Sep 2009 Link to this post

    Hello erwin,

    I understand. Nevertheless, we think that the behavior is wrong and we will correct it. However, I was not able to find a general solution. This is the reason why I said that there is no work around. We will appreciate if you share your solution with the community.

    Regards,
    Jack
    the Telerik team

    Instantly find answers to your questions on the new Telerik Support Portal.
    Watch a video on how to optimize your support resource searches and check out more tips on the blogs.
Back to Top