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

Loading Panel not working when using filter buttons to filter and rebind radgrid

1 Answer 105 Views
Grid
This is a migrated thread and some comments may be shown as answers.
John
Top achievements
Rank 1
John asked on 29 Jan 2015, 09:13 PM

Hi,

I have radgrid where the loading panel works when I enter larger page size like from 50 to 350 items per page. Then the spinning loading panel appears. I have a group of radcombobox to make selection to filter down the amount of records. When I click on the radbutton to apply the filter selection and rebind the datatable to the radgrid datasource, the loading panel does not appear. Any help is greatly appreciated.







<telerik:RadAjaxPanel runat="server" ID="pnlRadAjax">

        <asp:Panel runat="server" ID="pnlFilter">
             <div class="contentGroupHeading">
                <table>
                    <tr>
                        <td style="width: 100%"><asp:Label ID="lblFilter" runat="server" style="text-align:center" Text="Petitions Workload Filters" /></td>
                    </tr>
                </table>
             </div>
            <br />
            <table>
                <tr>
                    <td><asp:Label runat="server" ID="lblSDNType" Text="SDN Type: " Font-Bold="true"></asp:Label></td>
                    <td><telerik:RadComboBox runat="server" ID="rcbSDNType" DataTextField="SDN_TYPE" CheckBoxes="true" EnableCheckAllItemsCheckBox="true"></telerik:RadComboBox></td>
                    <td></td>
                    <td><asp:Label runat="server" ID="lblDetermination" Text="Determination: " Font-Bold="true"></asp:Label></td>
                    <td><telerik:RadComboBox runat="server" ID="rcbDetermination" DataTextField="DETERMINATION" CheckBoxes="true" EnableCheckAllItemsCheckBox="true"></telerik:RadComboBox></td>
                    <td></td>
                    <td><asp:Label runat="server" ID="lblStatusCode" Text="Status Code: " Font-Bold="true"></asp:Label></td>
                    <td><telerik:RadComboBox runat="server" ID="rcbStatusCode" DataTextField="STATUS_CODE" CheckBoxes="true" EnableCheckAllItemsCheckBox="true"></telerik:RadComboBox></td>
                </tr>
                <tr>
                    <td><asp:Label runat="server" ID="lblCaseType" Text="Case Type: " Font-Bold="true"></asp:Label></td>
                    <td><telerik:RadComboBox runat="server" ID="rcbCaseType" DataTextField="CASE_TYPE" CheckBoxes="true" EnableCheckAllItemsCheckBox="true"></telerik:RadComboBox></td>
                    <td></td>
                    <td><asp:Label runat="server" ID="lblOwnerType" Text="Owner Type: " Font-Bold="true"></asp:Label></td>
                    <td><telerik:RadComboBox runat="server" ID="rcbOwnerType" DataTextField="OWNER_TYPE" CheckBoxes="true" EnableCheckAllItemsCheckBox="true"></telerik:RadComboBox></td>
                    <td></td>
                    <td><asp:Label runat="server" ID="lblIsPrimaryInvestigator" Text="Is Primary Investigator: " Font-Bold="true"></asp:Label></td>
                    <td><telerik:RadComboBox runat="server" ID="rcbIsPrimaryInvestigator" DataTextField="IS_PRIMARY_INVESTIGATOR" CheckBoxes="true" EnableCheckAllItemsCheckBox="true"></telerik:RadComboBox></td>
                </tr>
                <tr>
                    <td><asp:Label runat="server" ID="lblProgram" Text="Program: " Font-Bold="true"></asp:Label></td>
                    <td><telerik:RadComboBox runat="server" ID="rcbProgram" DataTextField="PROGRAM" CheckBoxes="true" EnableCheckAllItemsCheckBox="true"></telerik:RadComboBox></td>
                    <td></td>
                    <td><asp:Label runat="server" ID="lblInvestigatorDivision" Text="Investigator Division: " Font-Bold="true"></asp:Label></td>
                    <td><telerik:RadComboBox runat="server" ID="rcbInvestigatorDivision" DataTextField="INVESTIGATOR_DIVISION" CheckBoxes="true" EnableCheckAllItemsCheckBox="true"></telerik:RadComboBox></td>
                    <td colspan="4"></td>
                </tr>
                <tr>
                    <td colspan="4">&nbsp;</td>
                </tr>
                <tr>                   
                    <td><telerik:RadButton runat="server" ID="rbtnFilter" Text="Filter Results" OnClick="rbtnFilter_Click"></telerik:RadButton></td>
                    <td><telerik:RadButton runat="server" ID="rbtnClearFilter" Text="Clear Filters" OnClick="rbtnClearFilter_Click"></telerik:RadButton></td>
                </tr>
            </table>
            <br />
            <br />
        </asp:Panel>

 

        <br />

        <asp:Panel runat="server" ID="pnlInvestigatorPetition" >
            <div class="contentGroupHeading">
                <table>
                    <tr>
                        <td style="width: 100%"><asp:Label ID="Label1" runat="server" style="text-align:center" Text="Investigator Petition" /></td>
                        <td><asp:ImageButton ID="imgExcel" runat="server" ImageUrl="~/Images/Excel_Icon.gif" OnClick="imgExcel_Click" AlternateText="Raw Export" ToolTip="Export Unformatted Excel (for data analysis)" /></td>
                        <td>&nbsp&nbsp</td>
                        <td><asp:ImageButton runat="server" ID="imgExcelFormatted" ImageUrl="~/images/Excel_Icon.gif" OnClick="imgExcel_Click" AlternateText="Formatted Export" ToolTip="Export Formatted Excel (for presentation)" /></td>
                    </tr>
                </table>
            </div>
            <br />
            <telerik:RadGrid ID="gridInvestigatorPetition" runat="server" HeaderStyle-Font-Bold="true"
                GridLines="none"
                Skin="OFACStyle"
                AllowSorting="True"  AllowPaging="true" PageSize="50"
                EnableEmbeddedSkins="false"
                ShowGroupPanel="True"
                AutoGenerateColumns="False" 
                PagerStyle-AlwaysVisible="true"
                MasterTableView-ShowGroupFooter="true"
                OnPreRender="gridInvestigatorPetition_PreRender"
                OnItemDataBound="gridInvestigatorPetition_ItemDataBound"
                OnNeedDataSource="gridInvestigatorPetition_NeedDataSource">   
            <GroupHeaderItemStyle ForeColor="Black" Font-Size="Medium"/>
            <PagerStyle Mode="NextPrevNumericAndAdvanced"></PagerStyle>
            <MasterTableView Width="100%" AllowMultiColumnSorting="true" DataKeyNames="SDN_UID">
            <GroupByExpressions>
                <telerik:GridGroupByExpression>
                    <SelectFields>
                        <telerik:GridGroupByField FieldName="INVESTIGATOR_DIVISION" HeaderText="Investigator Division" />
                    </SelectFields>
                    <GroupByFields>
                        <telerik:GridGroupByField FieldName="INVESTIGATOR_DIVISION" HeaderText="Investigator Division" SortOrder="Ascending"  />
                    </GroupByFields>
                </telerik:GridGroupByExpression>
                <telerik:GridGroupByExpression>
                    <SelectFields>
                        <telerik:GridGroupByField FieldName="PRIMARY_INVESTIGATOR" HeaderText="Primary Investigator" />
                    </SelectFields>
                    <GroupByFields>
                        <telerik:GridGroupByField FieldName="PRIMARY_INVESTIGATOR" HeaderText="Primary Investigator" />
                    </GroupByFields>
                </telerik:GridGroupByExpression>
            </GroupByExpressions>
            <Columns>

                <telerik:GridBoundColumn SortExpression="INVESTIGATOR_DIVISION" HeaderText="Investigator Division" HeaderButtonType="TextButton" DataField="INVESTIGATOR_DIVISION" ></telerik:GridBoundColumn>
                <telerik:GridBoundColumn SortExpression="PRIMARY_INVESTIGATOR" HeaderText="Primary Investigator" HeaderButtonType="TextButton" DataField="PRIMARY_INVESTIGATOR" Aggregate="Min" FooterAggregateFormatString="{0} Total"></telerik:GridBoundColumn>
                <telerik:GridBoundColumn SortExpression="CASE_STATUS" HeaderText="Case Status" HeaderButtonType="TextButton" DataField="CASE_STATUS"></telerik:GridBoundColumn>
                <telerik:GridBoundColumn SortExpression="PRIORITY" HeaderText="Priority" HeaderButtonType="TextButton" DataField="PRIORITY"></telerik:GridBoundColumn>
                <telerik:GridBoundColumn SortExpression="CASE_ID" HeaderText="Case ID" HeaderButtonType="TextButton" DataField="CASE_ID"></telerik:GridBoundColumn>
                <telerik:GridBoundColumn SortExpression="PROGRAM" HeaderText="Program" HeaderButtonType="TextButton" DataField="PROGRAM"></telerik:GridBoundColumn>
                <telerik:GridBoundColumn SortExpression="SDN" HeaderText="SDN" HeaderButtonType="TextButton" DataField="SDN"></telerik:GridBoundColumn>
                <telerik:GridBoundColumn SortExpression="RESPONSIBLE_PARTY" HeaderText="Responsible Party" HeaderButtonType="TextButton" DataField="RESPONSIBLE_PARTY"></telerik:GridBoundColumn>
               
                <telerik:GridTemplateColumn DataField="DAYS_ON_CLOCK" UniqueName="ChartColumn" HeaderText="">
                        <ItemTemplate>
                            <div style="width: 100px; height: 50px;">
                                <telerik:RadHtmlChart ID="htmlChartDaysOnClock" runat="server" Width="100" Height="50" Legend-Appearance-Visible="false" PlotArea-YAxis-MaxValue="1000" PlotArea-XAxis-MaxValue="1000" PlotArea-XAxis-MajorGridLines-Visible="false" PlotArea-XAxis-MinorGridLines-Visible="false" PlotArea-YAxis-MajorGridLines-Visible="false" PlotArea-YAxis-MinorGridLines-Visible="false" PlotArea-YAxis-Visible="false" PlotArea-XAxis-Visible="false" >
                                    <Legend>
                                        <Appearance Visible="false">
                                        </Appearance>
                                    </Legend>
                                    <PlotArea>
                                        <Series>
                                            <telerik:BarSeries DataFieldY="quantity">
                                                <LabelsAppearance Visible="false">
                                                </LabelsAppearance>
                                                <TooltipsAppearance Color="White" />
                                            </telerik:BarSeries>
                                        </Series>
                                        <XAxis DataLabelsField="pName">
                                        </XAxis>
                                    </PlotArea>
                                </telerik:RadHtmlChart>
                            </div>
                        </ItemTemplate>
                </telerik:GridTemplateColumn>
               
               
                <telerik:GridBoundColumn SortExpression="DAYS_ON_CLOCK" HeaderText="Days On Clock" HeaderButtonType="TextButton" DataField="DAYS_ON_CLOCK"></telerik:GridBoundColumn>
                <telerik:GridBoundColumn SortExpression="NO_OF_CASES" HeaderText="# of Cases" HeaderButtonType="TextButton" DataField="NO_OF_CASES" UniqueName="TotalCases" Aggregate="Sum" FooterText="Total Cases: "></telerik:GridBoundColumn>
                <telerik:GridBoundColumn SortExpression="NO_OF_TARGETS" HeaderText="# of Targets" HeaderButtonType="TextButton" DataField="NO_OF_TARGETS" UniqueName="TotalTargets" Aggregate="Sum" FooterText="Total Targets: "></telerik:GridBoundColumn>
            </Columns>
        </MasterTableView>
            <ClientSettings ReorderColumnsOnClient="True" AllowDragToGroup="True" AllowColumnsReorder="True">
                <Selecting AllowRowSelect="True"></Selecting>
                <Resizing AllowRowResize="True" AllowColumnResize="True" EnableRealTimeResize="True" ResizeGridOnColumnResize="False"></Resizing>
            </ClientSettings>
            <GroupingSettings ShowUnGroupButton="true" RetainGroupFootersVisibility="true"></GroupingSettings>
        </telerik:RadGrid>
    </asp:Panel>

    </telerik:RadAjaxPanel>

    <telerik:RadAjaxLoadingPanel ID="LoadingPanel1" runat="server" Skin="Windows7"></telerik:RadAjaxLoadingPanel>

    </div>
</asp:Content>

1 Answer, 1 is accepted

Sort by
0
Konstantin Dikov
Telerik team
answered on 03 Feb 2015, 12:30 PM
Hello John,

I have to say that it is rather strange that the RadAjaxLoadingPanel is displayed when you change the page size of the grid, because you are not setting the RadAjaxLoadingPanel's ID to the RadAjaxPanel's LoadingPanelID property, so it is expected to not see any RadAjaxLoadingPanel on AJAX requests within the RadAjaxPanel.

Can you please set the LoadingPanelID property of the RadAjaxPanel and see if everything will work correctly afterwords:
<telerik:RadAjaxPanel runat="server" ID="pnlRadAjax" LoadingPanelID="LoadingPanel1">
   

Best Regards,
Konstantin Dikov
Telerik
 

Check out the Telerik Platform - the only platform that combines a rich set of UI tools with powerful cloud services to develop web, hybrid and native mobile apps.

 
Tags
Grid
Asked by
John
Top achievements
Rank 1
Answers by
Konstantin Dikov
Telerik team
Share this question
or