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

No Loading panel with ClientIDMode="Static" on triggers

1 Answer 125 Views
Ajax
This is a migrated thread and some comments may be shown as answers.
Jeremy
Top achievements
Rank 1
Jeremy asked on 19 Oct 2011, 07:27 AM
I thought I'd share this solution here to save anyone else the hours of tearing hair out that I've had.

I had a master page and user controls using RadAjaxProxyManagers and the RadAjaxLoadingPanel was displaying for some buttons and not others. I played around with the setup of the page and narrowed it down to the buttons that had causesvalidation="false" were the ones that worked as expected.

This however was a red herring, as I eventually discovered the problem was caused by having ClientIDMode set to Static on the radbuttons! Why does setting ClientIDMode="Static" break showing the loading panel, but everything else functions fine?

<asp:Content ID="bodyPlaceholder" ContentPlaceHolderID="BodyPlaceHolder" runat="server">
 
  <div id="wrapper" runat="server">
 
    <!-- various grids etc -->
 
    <div>
       <div class="left">
         <telerik:RadButton runat="server" ID="addButton" ClientIDMode="Static" Text="Add" OnClick="Add" />
       </div>
       <div class="right">
         <telerik:RadButton runat="server" ID="okButton" ClientIDMode="Static" Text="OK" OnClick="Ok" />
         <telerik:RadButton runat="server" ID="cancelButton" ClientIDMode="Static" Text="Cancel" OnClick="Cancel" CausesValidation="false" />
          </div>
          <div class="clear">
        </div>
      </div>
  </div>
 
  <telerik:RadAjaxManagerProxy runat="server" ID="ajaxProxy" ClientIDMode="Static">
    <AjaxSettings>
      <telerik:AjaxSetting AjaxControlID="ajaxProxy">
        <UpdatedControls>
          <telerik:AjaxUpdatedControl ControlID="wrapper" LoadingPanelID="loadingPanel" />
        </UpdatedControls>
      </telerik:AjaxSetting>
      <telerik:AjaxSetting AjaxControlID="wrapper">
        <UpdatedControls>
          <telerik:AjaxUpdatedControl ControlID="wrapper" LoadingPanelID="loadingPanel" />
        </UpdatedControls>
      </telerik:AjaxSetting>
    </AjaxSettings>
  </telerik:RadAjaxManagerProxy>
 
  <telerik:RadAjaxLoadingPanel runat="server" ID="loadingPanel" />
 
</asp:Content>


1 Answer, 1 is accepted

Sort by
0
Tsvetina
Telerik team
answered on 21 Oct 2011, 01:13 PM
Hi Jeremy,

Currently RadControls for ASP.NET AJAX do not offer support for ClientIDMode different than AutoID. Since these are controls with complex hierarchies of child controls and templates, setting their ClientID mode to Static will break most of their client functionality. Please note that even Microsoft does not recommend setting ClientIDMode="Static" on pages which do contain dynamic controls.

Kind regards,
Tsvetina
the Telerik team
If you want to get updates on new releases, tips and tricks and sneak peeks at our product labs directly from the developers working on the RadControls for ASP.NET AJAX, subscribe to their blog feed now
Tags
Ajax
Asked by
Jeremy
Top achievements
Rank 1
Answers by
Tsvetina
Telerik team
Share this question
or