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

RadAjaxLoadingPanel in Sitefinity Widget

1 Answer 97 Views
Ajax
This is a migrated thread and some comments may be shown as answers.
Compton
Top achievements
Rank 1
Compton asked on 16 Oct 2012, 07:44 PM

I have a Sitefinity Widget on a page with a template that is a custom master page.  The updated control is buried insite a MultiView.  The Ajax request seems to work fine, but my loading panel does not appear.  I've tried attaching ResponseEnd and RequestStart events, but they don't fire either.  I've read a large number for forum posts on people having trouble getting RadAjaxLoadingPanels to appear, but none of these solutions have worked for me.  Is there anything else I can try?

Thanks.

In page.master for the custom template:
<telerik:RadScriptManager ID="RadScriptManager1" runat="server">
</telerik:RadScriptManager>

<telerik:RadAjaxManager ID="RadAjaxManager1"   runat="server">
</telerik:RadAjaxManager>

In Sitefinity Widget .aspx:
   <telerik:RadAjaxManagerProxy ID="RadAjaxManagerProxy1" runat="server"> 
        <AjaxSettings>
            <telerik:AjaxSetting AjaxControlID="HomeFilterPanel1">
                <UpdatedControls>
                    <telerik:AjaxUpdatedControl ControlID="RadListViewHomesPanel" LoadingPanelID="MyLoadingPanel" />
                </UpdatedControls>
            </telerik:AjaxSetting>
        </AjaxSettings>
    </telerik:RadAjaxManagerProxy>

    <telerik:RadAjaxLoadingPanel ID="MyLoadingPanel"  ClientIDMode="Static" runat="server" MinDisplayTime="2000"  Skin="Default"  Visible="true">
    <asp:Label ID="Label2" runat="server" ForeColor="Red">Loading... </asp:Label>

 <%-- <asp:Image ID="Image1" runat="server" Width="224px" Height="48px" ImageUrl="~/Loading.gif" />--%>
</telerik:RadAjaxLoadingPanel>

        <telerik:RadScriptBlock ID="RadScriptBlock1" runat="server">
            <script type="text/javascript">
                function RequestStart(sender, args) {
                    alert('RequestStart');
                }

                function ResponseEnd() {
                    alert('ResponseEnd');
                }
            </script>
        </telerik:RadScriptBlock>

 

In Sitefinity Widget .cs:
        protected void Page_Load(object sender, EventArgs e)
        {
            RadAjaxManager manager = RadAjaxManager.GetCurrent(this.Page);
            if (manager != null)
            {
                manager.ClientEvents.OnRequestStart = "RequestStart";
               manager.ClientEvents.OnResponseEnd = "ResponseEnd";         
            }

            RadAjaxManager.GetCurrent(Page).AjaxSettings.AddAjaxSetting(RadAjaxManager.GetCurrent(Page), RadListViewHomesPanel, this.MyLoadingPanel);

        }

1 Answer, 1 is accepted

Sort by
0
Maria Ilieva
Telerik team
answered on 19 Oct 2012, 01:24 PM
Hello Compton,

Please try to set the ClientIDMode for the RadAjaxLoadingPanel to "Auto" and verify of this makes any difference. Also please make sure that all controls added as ajax initiators or updated by the RadAjax are with ClientIDMode set to "Auto" as this is required for the proper execution of the ajax request.

Greetings,
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
Compton
Top achievements
Rank 1
Answers by
Maria Ilieva
Telerik team
Share this question
or