Time Picker

6 posts, 0 answers
  1. Mathews
    Mathews avatar
    16 posts
    Member since:
    Jun 2008

    Posted 19 Aug 2008 Link to this post

    Hello
    i  had a problem with time picker(rad).am using 1.2.2.1 version.

    <

    radCln:RadTimePicker ID="tpArrivalTime" runat="server">

    <TimeView runat="server" StartTime="0:0:0" EndTime="23:31:00" Interval="0:30:0" Columns="5" TimeFormat="HH:mm"

    Culture="en-US">

    </TimeView>

    <DateInput DateFormat="HH:mm" Culture="en-US">

    </DateInput>

    <DatePopupButton Visible="False" />

    </radCln:RadTimePicker>
    am not getting the selected time .am getting the selected date with time.do this control have property to get time itself or else how to get the value in the textbox field after selecting the time (in code behind not javascript)

    regards
    Mathews Baby

  2. Princy
    Princy avatar
    17421 posts
    Member since:
    Mar 2007

    Posted 19 Aug 2008 Link to this post

    Hello Mathews,

    Check out the following code snippet to achieve the required scenario.
    aspx:
    <rad:RadTimePicker id="RadTimePicker1" Runat="server" AutoPostBack="True" OnSelectedDateChanged="RadTimePicker1_SelectedDateChanged"
          <timeview skin=""></timeview> 
          <dateinput autopostback="True" skin=""></dateinput> 
          <datepopupbutton visible="False"></datepopupbutton> 
    </rad:RadTimePicker> 

    cs:
    protected void RadTimePicker1_SelectedDateChanged(object sender, SelectedDateChangedEventArgs e) 
        { 
            string strDateRadTimePicker1.SelectedDate.Value.ToShortTimeString(); 
        } 

    Thanks
    Princy.
  3. UI for ASP.NET Ajax is Ready for VS 2017
  4. Mathews
    Mathews avatar
    16 posts
    Member since:
    Jun 2008

    Posted 19 Aug 2008 Link to this post

    thanks for the reply Princy

    Hello one more think to ask
    how can i set time to timepicker(rad).from database am returning ''12:45 PM".
    i need to set this value to time picker.
    RadTimePicker1.selecteddate="12:45"
    but its not reflecting ;its showing default 12:00
    plese send me reply soon

    regards
    Mathews Baby
  5. Shaun Peet
    Shaun Peet avatar
    571 posts
    Member since:
    Aug 2004

    Posted 19 Aug 2008 Link to this post

    RadTimePicker1.SelectedDate = New Date(Today.Year, Today.Month, Today.Day, 12, 45, 0)
  6. Randy
    Randy avatar
    23 posts
    Member since:
    Jul 2012

    Posted 08 Mar 2010 Link to this post

    This isn't working.  No matter what I do I can't set the time from the code behind.

    protected void rdpEndDate_Load(object sender, EventArgs e)  
            {  
                this.rdpEndDate.SelectedDate  = new DateTime(getThisFriday(System.DateTime.Now).Year, getThisFriday(System.DateTime.Now).Month, getThisFriday(System.DateTime.Now).Day, 23, 59, 59);  
            }  
            protected void rdpEndDate_SelectedDateChanged(object sender, Telerik.Web.UI.Calendar.SelectedDateChangedEventArgs e)  
            {  
                this.rdpEndDate.SelectedDate = new DateTime(e.NewDate.Value.Year, e.NewDate.Value.Month, e.NewDate.Value.Day, 23, 59, 59);  
            }  
            protected void rdpStartDate_Load(object sender, EventArgs e)  
            {  
                this.rdpStartDate.SelectedDate = Convert.ToDateTime(getLastFriday(System.DateTime.Now).ToShortDateString());  
                 
            } 
  7. Sebastian
    Admin
    Sebastian avatar
    9934 posts

    Posted 09 Mar 2010 Link to this post

    Hello Randy,

    Review my reply in the other forum thread you participated in which discusses the same subject:
    http://www.telerik.com/community/forums/aspnet-ajax/general-discussions/174989-datetimepicker-problem.aspx

    Kind regards,
    Sebastian
    the Telerik team

    Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items.
Back to Top
UI for ASP.NET Ajax is Ready for VS 2017