Several Loading Panels in a Page

5 posts, 0 answers
  1. Preetam Ray
    Preetam Ray avatar
    47 posts
    Member since:
    Oct 2007

    Posted 05 Apr 2010 Link to this post

    I have a Web Form which contains a user control say x. User control x contains several instances of a single user control y.
    y contains a loading panel in which a image is present for display on click of a particular button. Say i repeat user control y 3 or 4 times on the user control x.

    The loading panel in my case contains the image that needs to be displayed on click of a button. So, when the form is loaded i would have 3 or 4 loading panels and also its corresponding 3 or 4 proxies.

    <telerik:RadAjaxLoadingPanel height="30" width="100" isSticky="true" id="loadingPane" runat="server" style="position:absolute;">
                        <asp:Image id="loadingImg" runat="server" ImageUrl="/_layouts/images/factiva/loading.gif" AlternateText="Loading..." BorderWidth="0"></asp:Image>
                    </telerik:RadAjaxLoadingPanel>

    <asp:Panel id="searchTreePanel" runat="server">
                            <telerik:RadTreeview id="rSTreeView" runat="server" EnableEmbeddedSkins="false" Skin="FactivaGray"></telerik:RadTreeview>                        
                            </asp:Panel>

    <telerik:RadAjaxManagerProxy id="rAjaxManager" runat="server">
        <AjaxSettings>
            <telerik:AjaxSetting AjaxControlID="searchGo">
                <UpdatedControls>
                    <telerik:AjaxUpdatedControl ControlID="searchTreePanel" LoadingPanelID="loadingPane" />
                </UpdatedControls>
            </telerik:AjaxSetting>
        </AjaxSettings>
    </telerik:RadAjaxManagerProxy>

    The issue i am facing is that no matter i click any of the three or four searchGo buttons i get the same image loaded and not the different one.
    Any help would be great.




  2. Preetam Ray
    Preetam Ray avatar
    47 posts
    Member since:
    Oct 2007

    Posted 06 Apr 2010 Link to this post

    Is there someone who could help me on this?
  3. farsica
    farsica avatar
    41 posts
    Member since:
    Aug 2005

    Posted 06 Apr 2010 Link to this post

    when using radajaxmanager for each control that update by it show loading image.
    if you want to show just 1 loader image in your page like gmail/yahoo dosn't use RadAjaxLoadingPanel. then you need to use OnRequestStart and OnResponseEnd events of RadAjaxManager.
    in OnRequestStart event you must add function to show your loader image and on OnResponseEnd hide it.
    you can create a div with a image inside it with (<div id="divId" style="display:none;"><img src="" alt=""/></div>), then at OnRequestStart  set for example $get("divId").style.display="visible"   and at OnResponseEnd $get("divId").style.display="none"
  4. Preetam Ray
    Preetam Ray avatar
    47 posts
    Member since:
    Oct 2007

    Posted 07 Apr 2010 Link to this post

    Am sorry, i really did not understand your first line.. Can you explain.
    Further, as i explained each usercontrol i add to the parent user control contains a loading image, and i need to show that particular loading image for that particular update. This parent user control is then placed in the web page.
  5. farsica
    farsica avatar
    41 posts
    Member since:
    Aug 2005

    Posted 07 Apr 2010 Link to this post

    the first line says that when with ajaxmanager you control for example 3 page controls,it show 3 image loader.
    in your senario ajaxmanager find 4 control with id "searchGo" therefore show loader image for all.
    if you want to each part has its loader image you can use radajaxpanel instead of radajaxmanager
Back to Top