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

[Solved] Issue when a grid control has user control for editing with another grid inside.

2 Answers 169 Views
Grid
This is a migrated thread and some comments may be shown as answers.
Ivo
Top achievements
Rank 1
Ivo asked on 12 Mar 2008, 01:41 PM
Hello,

I have a page with a Prometheus grid control with a user control for editing. The user control itself has another Prometheus grid and I want to be able to sort and page and select records from the second grid in the user control, but when I try to sort the second grid the whole user control disappears. Also, the page scroll bar, for paging the grid, is not visible in the second grid, even it shows 1 of 15 pages.
When I put the user control in a separate page it seems to work correctly.

I have only one rad script manager control in the page. The user controls has only RadAjaxManager.

I am wondering if there is a way to allow the grid functionality on the user control which is a part of the main grid.


Thanks,
Ivo

2 Answers, 1 is accepted

Sort by
0
Ivo
Top achievements
Rank 1
answered on 13 Mar 2008, 02:01 AM

Thread Update:

After further investigation I realized that the issue happens because the main grid, in the example, has view state disabled (for performance reason). With view state enabled the second gird in the user control works as expected.

I would like to check if it is possible to have the same functionality, as described in the first post, with disabled view state.

0
Sebastian
Telerik team
answered on 17 Mar 2008, 12:35 PM
Hi Ivo,

Advanced features like grouping, filtering, data editing with custom edit forms (UserControl or FormTemplate) require the viewstate of the grid to be enabled. Hence you will need to switch on the viewstate for the grid wrapper to ensure that the WebUserControl custom edit form (and the other grid inside it) will function properly.

A possible workaround for you might be to save the parent grid's viewstate in the Session as explained in this topic from the online help.

Best regards,
Stephen
the Telerik team

Instantly find answers to your questions at the new Telerik Support Center
Tags
Grid
Asked by
Ivo
Top achievements
Rank 1
Answers by
Ivo
Top achievements
Rank 1
Sebastian
Telerik team
Share this question
or