RadSlider not visible on RadWindow

3 posts, 0 answers
  1. Marco Miccini
    Marco Miccini avatar
    17 posts
    Member since:
    Aug 2009

    Posted 10 Jan 2010 Link to this post

    I've an aspx page with inside a <RadWindow ...><ContentTemplate><telerik:RadSlider id="rl" ...></ContenTemplate></RadWindow> .
    The RadWindow is set with VisibleOnPageLoad="true".
    In the RadWindow I can see all the controls except the RadSliders that remains not visible: why?
    I've tried to call a javascript function on the OnClientShow of the RadWindow to repaint the sliders as suggested in an anwser in these forums as follows:



    OnClientShow(sender, eventArgs) {
    var wnd = $find("<%= rl.ClientID %>");



    Unfortunately it does not compile since the "rl" control is inside a ContentTemplate and I do not know how to access this element from javscript.
    Any help?

  2. Tsvetie
    Tsvetie avatar
    1517 posts

    Posted 11 Jan 2010 Link to this post

    Hi Marco Miccini,
    You can use the following approach to get a reference to the slider control:
    <form id="form1" runat="server">
        <asp:ScriptManager ID="ScriptManager1" runat="server"></asp:ScriptManager>
        <telerik:RadWindow ID="RadWindow1" runat="server" VisibleOnPageLoad="true" OnClientShow="OnClientShow">
                <telerik:RadSlider ID="RadSlider1" runat="server"></telerik:RadSlider>
        <script type="text/javascript">
        function OnClientShow(sender, args)
            $find('<%= RadWindow1.ContentContainer.FindControl("RadSlider1").ClientID %>').repaint();

    Kind regards,
    the Telerik team

    Instantly find answers to your questions on the new Telerik Support Portal.
    Watch a video on how to optimize your support resource searches and check out more tips on the blogs.
  3. Marco Miccini
    Marco Miccini avatar
    17 posts
    Member since:
    Aug 2009

    Posted 11 Jan 2010 Link to this post

    Dear Tsvetie,
    thanks a lot for your help, your support at Telerik is always fantastic!
    Now the javascript works and, more important, the comboboxes in the RadWindows are finally visible.
Back to Top