Grid detail does not remain collapsed after page change

2 posts, 0 answers
  1. Oscar
    Oscar avatar
    1 posts
    Member since:
    Oct 2020

    Posted 27 Oct Link to this post

    Hello everyone,

    I'm having an issue with expanded grid details. I have a collapseAll method with a forEach inside that iterates every item that loads in my grid and uses collapseRow to close them on load.

    Now this works for page 1, but if I move to page 2 and decide to expand any details , then I switch back to page 1 and return to 2, the grid details remain expanded when they should collapse since I have a call to collapseAll on pageLoad method. Is there some index issue that fails to capture indexes outside of page1?

  2. Svetlin
    Svetlin avatar
    448 posts

    Posted 29 Oct Link to this post

    Hi Oscar,

    I am not sure what is the exact implementation on your side. But as long as the functionality is as expected for the first page and not for the other pages, then it seems that the collapseRow() method is used improperly. Probably you are passing some incorrect indexes to it. Generally, the row index depends on the absolute index of the item on the page, the pageSize and the current page. For example the index of the third row on the first page when using a pageSize of 10 would be 2 and the index of the third row on the second page when using a pageSize of 10 would be 12.

    We have also provided the ExpandDetailsDirective which controls the expanded state of the master details Grids. Please check it at the followin link:

    I hope the provided information helps.

    Progress Telerik

    Virtual Classroom, the free self-paced technical training that gets you up to speed with Telerik and Kendo UI products quickly just got a fresh new look + new and improved content including a brand new Blazor course! Check it out at

Back to Top