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

RadAjax Loading Panel only shows on first ajax request

1 Answer 84 Views
Ajax
This is a migrated thread and some comments may be shown as answers.
Acadia
Top achievements
Rank 1
Acadia asked on 04 May 2012, 09:44 PM
This has been baffling (and infuriating me) for hours now.  I have a textbox wrapped inside a panel named:

<asp:Panel ID="panelTest" runat="server">


The textbox calls a javascript event when the user hits enter:
function CatchTab(e) {
               var keycode;
               if (window.event) {
                   keycode = window.event.keyCode;
               } else if (e) {
                   keycode = e.which || e.keyCode;
               } else {
                   return true;
               }
 
               if (keycode == 13) {
                   //alert("User Hit Enter");
                   var empid = document.getElementById('<%= tbTmid.ClientID %>').value;
                   InitiateAjaxRequest(empid);
               }
           }


function InitiateAjaxRequest(arguments) {
               var ajaxManager = $find("<%= ram2.ClientID %>");
               alert("Initiating Request");
               ajaxManager.ajaxRequest(arguments);
           }

<telerik:RadAjaxManager ID="ram2" runat="server" Skin="Web20" OnRequestStart="InitiateAjaxRequest">
        <AjaxSettings>
            <telerik:AjaxSetting AjaxControlID="ram2">
                <UpdatedControls>
                    <telerik:AjaxUpdatedControl ControlID="panelTest" LoadingPanelID="loader1" />
                </UpdatedControls>
            </telerik:AjaxSetting>
            <telerik:AjaxSetting AjaxControlID="rgSc">
                <UpdatedControls>
                    <telerik:AjaxUpdatedControl ControlID="panelTest" LoadingPanelID="loader1" />
                    <telerik:AjaxUpdatedControl ControlID="rwm1" LoadingPanelID="loader1" />
                </UpdatedControls>
            </telerik:AjaxSetting>
        </AjaxSettings>
    </telerik:RadAjaxManager>
 
    <telerik:RadAjaxLoadingPanel ID="loader1" runat="server" Skin="Web20" IsSticky="false"
            EnableViewState="true" Enabled="true">
    </telerik:RadAjaxLoadingPanel>


For some reason the darn loading panel only wants to show up on the first ajax request.  Everything is ajaxd on subsequent requests, I just don't see any loading panel.  The textbox fills a grid within the panel.  What's even stranger is that if the value entered into the textbox does not return any grid rows, the loading panel shows up everytime!!!

Also, I get the "Initiating Request" alert every time as well and the ajax manager object is always populated (not null).

If anyone could please help that would be great.

Thanks

1 Answer, 1 is accepted

Sort by
0
Maria Ilieva
Telerik team
answered on 09 May 2012, 01:55 PM
Hello Justin,

Could you please try to show and hide the LoadingPanel manually as shown in the following help topic:
http://www.telerik.com/help/aspnet-ajax/ajax-show-hide-loadingpanel.html

Give this a try and let me know if this makes any difference.

All the best,
Maria Ilieva
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
Acadia
Top achievements
Rank 1
Answers by
Maria Ilieva
Telerik team
Share this question
or