This is a migrated thread and some comments may be shown as answers.

[Solved] How-to: Maintain selected row

1 Answer 126 Views
Grid
This is a migrated thread and some comments may be shown as answers.
Søren Hartig
Top achievements
Rank 2
Søren Hartig asked on 20 May 2009, 12:44 PM
Hi,

I have a gridview that is dynamically contructed and I'm having problems with the LoadingPanel.  As a workaround the loading panel I used the PageRequestManager way to turn the visibility of the loading panel on and off, the problem now is that the selected row looses it seleced state onde the process ends:

Screencast url: http://is.gd/BFbu

What I want is a way to in the BeginRequest get the selected row (maybe from the sender?) and on the EndRequest say to the grid that there is a selected row assigning it the index.

As you see by the screencast I have a lot of grids, and this is all done dynamically, I do not know the grids name, I then really need to use the sender object to grab the current grid name that fired the request, and use this to get the selected Row, but I'm not abble to accomplish this... :(

Any help will be greatly apreciated.

Thank you.

1 Answer, 1 is accepted

Sort by
0
Iana Tsolova
Telerik team
answered on 25 May 2009, 10:15 AM
Hi Søren,

Indeed, RadGrid should persist it selected items state during postback. And the selected items are usually cleared only after explicit rebind. Could you specify how is your grid bound and how it is ajaxified?
If you are using RadAjax to ajaxify it, then just set the RadAjaxLoadingPanel ID as a LoadingPanelID in the ajax settings where the problematic grid is updated and it would automatically show/hide.

Additionally, you can check out this online demo which resembles your scenario.
Find more information on RadAjaxLoadingPanel usage here.

Check it out and let me know how it goes.

All the best,
Iana
the Telerik team

Instantly find answers to your questions on the new Telerik Support Portal.
Check out the tips for optimizing your support resource searches.
Tags
Grid
Asked by
Søren Hartig
Top achievements
Rank 2
Answers by
Iana Tsolova
Telerik team
Share this question
or