More on Persisting Groups Expanded States on Rebind

2 posts, 0 answers
  1. neebs
    neebs avatar
    106 posts
    Member since:
    Apr 2007

    Posted 24 Jan 2010 Link to this post

    I am using the example here:


    to preserve the expanded states of groups across postbacks. I am finding a situation where it is failing and I'm not sure why. For example, if I populate the grid, and expand a group, then refresh the page, the groups are expanded as expected. See Image 1. But, I have the grid set for AllowRowSelect in the ClientSettings of the grid. If I display the grid, expand a group and select a row, the row highlights as expected and the group stays expanded. If I then cause a refresh by clicking on a button on the page that rebinds the grid, the grid is expanded, and the group stays expanded. So far so good. But, after that, if I select a row, the grid group collapses, with the indicator left in the expanded state. See image 2. Even if the SelectedIndexChanged method is not set, the expanded state of the grid reverts to all groups collapsed, but the expanded buttons showing they're expanded.
  2. neebs
    neebs avatar
    106 posts
    Member since:
    Apr 2007

    Posted 25 Jan 2010 Link to this post

    Please ignore this posting, I found the problem. I was calling the code that expands/collapses groups in two places. Although the results were not what I would have expected, removing the redundant code fixed the problem.
    Steve
  3. UI for ASP.NET Ajax is Ready for VS 2017
Back to Top