RadSlidingPane - Open onload

2 posts, 0 answers
  1. Bader
    Bader avatar
    215 posts
    Member since:
    Aug 2008

    Posted 01 Aug 2011 Link to this post

    Hello,

    I have the folowing RadSplitter control.
    I need to expand the RadSlidingPane (ContentRadSlidingPane) onload, and to prevent the use from collapsing it (Exactly as http://www.telerik.com/help/aspnet-ajax/introduction.html).
    <telerik:RadSplitter ID="RadSplitter1" runat="server" Width="700" Height="500">
               <telerik:RadPane ID="LeftPane" runat="server" Width="22px" Scrolling="none">
                    <telerik:RadSlidingZone ID="ContentsSlidingZone" runat="server" Width="22px">
                        <telerik:RadSlidingPane ID="ContentRadSlidingPane" Title="Pane1" runat="server"  Width="150px">
                            Contents
                        </telerik:RadSlidingPane>
                    </telerik:RadSlidingZone>
                </telerik:RadPane>
                <telerik:RadSplitBar ID="Radsplitbar1" runat="server"></telerik:RadSplitBar>
                <telerik:RadPane ID="MiddlePane1" runat="server" Scrolling="None">
                    <telerik:RadSplitter ID="Radsplitter2" runat="server" Orientation="Horizontal" VisibleDuringInit="false">
                        <telerik:RadPane ID="Radpane2" runat="server">
                            <div style="padding: 5px">
                                <asp:ContentPlaceHolder id="ContentPlaceHolder1" runat="server">
             
                                </asp:ContentPlaceHolder>
                            </div>
                        </telerik:RadPane>
                    </telerik:RadSplitter>
                </telerik:RadPane>
            </telerik:RadSplitter>

    Please, I need you help,
    It is appreciated to send me the modified code.

    Regards,
    Bader
  2. Dobromir
    Admin
    Dobromir avatar
    1633 posts

    Posted 03 Aug 2011 Link to this post

    Hi Bader,

    In order to configure a sliding pane to be expanded when the page loads you need to set RadSlidingZone's ExpandedPaneId property to point to the required pane's ID. After that you can use one of the following approaches to prevent collapsing of the pane:
    1. Hide the collapse command using the following CSS:
      .rspSlideHeaderCollapseIcon
      {
          display:none !important;
      }
    2. Handle the RadSlidingPane's ClientBeforeCollapse client-side event and cancel its standard execution, e.g.:
      function OnClientBeforeCollapse(sender, args)
      {
          alert("This functionality is disabled!");
          args.set_cancel("true");
      }

    Here is the modified markup of the splitter:
    <telerik:RadSplitter ID="RadSplitter1" runat="server" Width="700" Height="500">
        <telerik:RadPane ID="LeftPane" runat="server" Width="22px" Scrolling="none">
            <telerik:RadSlidingZone ID="ContentsSlidingZone" runat="server" Width="22px" ExpandedPaneId="ContentRadSlidingPane">
                <telerik:RadSlidingPane ID="ContentRadSlidingPane" Title="Pane1" runat="server" Width="150px" OnClientBeforeCollapse="OnClientBeforeCollapse">
                    Contents
                </telerik:RadSlidingPane>
            </telerik:RadSlidingZone>
        </telerik:RadPane>
        <telerik:RadSplitBar ID="Radsplitbar1" runat="server">
        </telerik:RadSplitBar>
        <telerik:RadPane ID="MiddlePane1" runat="server" Scrolling="None">
            <telerik:RadSplitter ID="Radsplitter2" runat="server" Orientation="Horizontal" VisibleDuringInit="false">
                <telerik:RadPane ID="Radpane2" runat="server">
                    <div style="padding: 5px">
                        <asp:ContentPlaceHolder ID="ContentPlaceHolder1" runat="server">
                        </asp:ContentPlaceHolder>
                    </div>
                </telerik:RadPane>
            </telerik:RadSplitter>
        </telerik:RadPane>
    </telerik:RadSplitter>


    Kind regards,
    Dobromir
    the Telerik team

    Browse the vast support resources we have to jump start your development with RadControls for ASP.NET AJAX. See how to integrate our AJAX controls seamlessly in SharePoint 2007/2010 visiting our common SharePoint portal.

  3. UI for ASP.NET Ajax is Ready for VS 2017
Back to Top