RadDatePicker Calendar Popup on Side

3 posts, 1 answers
  1. Daniel
    Daniel avatar
    8 posts
    Member since:
    Jun 2009

    Posted 15 Feb 2012 Link to this post

    I have a modal popup window on my page using a RadWindow control. On the popup page I have a RadDatePicker control without a lot of space above or below it. When the calendar button is clicked the calendar popup displays below the control and causes the window to display scrollbars. I do not like this and since I have plenty of room on the right side of the control, I'd like to display the calendar popup over there. Is there some custom javascript I can use to display the calendar popup on the side instead of just above or below the control?

    Thanks,
    Dan
  2. Answer
    Princy
    Princy avatar
    17421 posts
    Member since:
    Mar 2007

    Posted 16 Feb 2012 Link to this post

    Hello,

    Try the following javascript.
    JS:
    <script type="text/javascript">
     function Popup_Side(e)
        {
           var datePicker = $find("<%=RadDatePicker1.ClientID %>");
           datePicker.showPopup(150,5);
         }
    </script>
    C#:
    RadDatePicker1.DatePopupButton.Attributes.Add("onclick", "Popup_Side(event);return false;"); //to attatch the event

    Thanks,
    Princy.
  3. UI for ASP.NET Ajax is Ready for VS 2017
  4. Daniel
    Daniel avatar
    8 posts
    Member since:
    Jun 2009

    Posted 16 Feb 2012 Link to this post

    Thank you so much for your quick reply! This saved me from many more hours of trial and error!
Back to Top