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

RadGrid inside RadWindow having issues in grid sorting

1 Answer 92 Views
Grid
This is a migrated thread and some comments may be shown as answers.
Suj
Top achievements
Rank 1
Suj asked on 27 Feb 2012, 12:46 PM
In my aspx page I have a RadPageView which contains RadWindow and the RadGrid is inside the RadWindow. (ie. RadMultiPage -> RadPageView -> RadWindow -> RadGrid).
<telerik:RadWindow EnableShadow="true" ShowContentDuringLoad="false" runat="server"
                                        ReloadOnShow="true" Title="Standard Text: Add Observation." OpenerElementID="lnkObservationsText"
                                        Behaviors="None" VisibleStatusbar="false" EnableViewState="true" ID="rdWndObservationText"
                                        Skin="Web20" Modal="true" Width="600">
                                        <ContentTemplate>
                                            <div class="RadModalMainDiv">
                                                <div>
                                                    <p>
                                                        Help text to go here....</p>
                                                </div>
                                                <div class="divStandardTextButtonList">
                                                    <asp:Button ID="btnObservationsTextSelect" runat="server" Text="Select" CssClass="btnStandardText"
                                                        OnClientClick="return ObservationStandardText_Confirm()" />
                                                    <asp:Button ID="btnObservationsTextCancel" runat="server" Text="Cancel" CssClass="btnStandardText" />
                                                </div>
                                                <asp:Panel ID="pnl1" runat="server">
                                                    <div>
                                                        <telerik:RadGrid ID="radGdObservationsText" runat="server" AllowPaging="True" AllowSorting="True"
                                                            AutoGenerateColumns="False" GridLines="None" PageSize="10" Width="100%">
                                                            <MasterTableView CommandItemDisplay="None" Name="ParentGrid">
                                                                <Columns>
                                                                    <telerik:GridClientSelectColumn UniqueName="ClientSelectColumn">
                                                                    </telerik:GridClientSelectColumn>
                                                                    <telerik:GridBoundColumn DataField="description" HeaderText="Observation Description"
                                                                        Visible="true">
                                                                    </telerik:GridBoundColumn>
                                                                </Columns>
                                                            </MasterTableView>
                                                            <PagerStyle Mode="NextPrevAndNumeric" />
                                                            <ClientSettings>
                                                                <Selecting AllowRowSelect="True" />
                                                                <ClientEvents OnRowSelected="SetObservationStandardText" />
                                                            </ClientSettings>
                                                        </telerik:RadGrid>
                                                    </div>
                                                </asp:Panel>
                                            </div>
                                        </ContentTemplate>
                                    </telerik:RadWindow>

When I try to sort the grid clicking on the header, the page refreshes and the RadWindow disappears. Sorting happens coz when i reopens the RadGrid the rows appea sorted. I need the RadGrid to be sroted and remain in the same state. Thanks for all helps in prior.

1 Answer, 1 is accepted

Sort by
0
Casey
Top achievements
Rank 1
answered on 27 Feb 2012, 03:40 PM
Hi Suj,

Could you please post the javascript function that is executed on row selected (SetObservationStandardText)? 

Thanks,
Casey
Tags
Grid
Asked by
Suj
Top achievements
Rank 1
Answers by
Casey
Top achievements
Rank 1
Share this question
or