TimeView Control

3 posts, 0 answers
  1. Shaun Peet
    Shaun Peet avatar
    571 posts
    Member since:
    Aug 2004

    Posted 11 Oct 2007 Link to this post

    Is there any way to get the TimeView control to always occupy space on the page, without requiring that it "pop-up"?  This is a usability thing as it requires two clicks to set the time when the "pop-up" is used and would only require one click if the TimeView was always visible.  If there's real estate available on the form then it would be nice to have that option.  I've created a series of div's that use an onclick javascript function to do the same, but it's nearly impossible to "link" the current time with my custom TimeView (so that it highlights the current one).
  2. Giuseppe
    Admin
    Giuseppe avatar
    2363 posts

    Posted 12 Oct 2007 Link to this post

    Hello Shaun Peet,

    You can achieve the desired functionality like this:

    <script type="text/javascript"
    function pageLoad() 
           
        window.setTimeout(function() 
                          { 
                            // override the default logic in order not to close the timeview  
                            // when clicking outside the timepicker 
                            Telerik.Web.UI.Calendar.Popup.prototype.ShouldHide = function(){return false;}; 
                             
                            // open the timeview on load 
                            $find("RadTimePicker1").ShowTimePopup(); 
                          }, 0); 
     
    // cancel closing on time selection through the timeview 
    function OnPopupClosing(sender, args) 
        args.set_cancel(true); 
    </script> 
     
    <telerik:RadTimePicker ID="RadTimePicker1" runat="server"
        <ClientEvents OnPopupClosing="OnPopupClosing" /> 
    </telerik:RadTimePicker> 



    All the best,
    Manuel
    the Telerik team

    Instantly find answers to your questions at the new Telerik Support Center
  3. UI for ASP.NET Ajax is Ready for VS 2017
  4. Shaun Peet
    Shaun Peet avatar
    571 posts
    Member since:
    Aug 2004

    Posted 14 Oct 2007 Link to this post

    Thanks Manuel.
Back to Top