Sorry if this is the incorrect forum board to post this topic, but I couldn't find a more relevant section.
I'm having an issue when specifying the SelectedDate attribute of the RadTimePicker. For some reason no matter when value I specify the displayed value is "12:00 AM". Why is this and how can I fix this?
Thanks for your help,
Curt.
I'm having an issue when specifying the SelectedDate attribute of the RadTimePicker. For some reason no matter when value I specify the displayed value is "12:00 AM". Why is this and how can I fix this?
Thanks for your help,
Curt.
4 Answers, 1 is accepted
0
Hello Curt,
Could you please elaborate a bit on your scenario? What version of the controls are you using? I am testing this with the latest official release of RadControls for Asp.Net Ajax but cannot observe any problem. If you can paste some of your markup here, or tell us how to reproduce it, we will be grateful.
Best wishes,
Pavel
the Telerik team
Instantly find answers to your questions at the new Telerik Support Center
Could you please elaborate a bit on your scenario? What version of the controls are you using? I am testing this with the latest official release of RadControls for Asp.Net Ajax but cannot observe any problem. If you can paste some of your markup here, or tell us how to reproduce it, we will be grateful.
Best wishes,
Pavel
the Telerik team
Instantly find answers to your questions at the new Telerik Support Center
0
Curt
Top achievements
Rank 1
answered on 20 May 2008, 09:32 AM
Thanks, Heres my source:
Dim TimeArranged As DateTime = 'Fetches datetime from database
date1.selecteddate = TimeArranged
time1.SelectedDate = TimeArranged.ToString("hh:mm")
date1 is a datepicker, time1 is a timepicker.
Thanks again,
Curt.
Dim TimeArranged As DateTime = 'Fetches datetime from database
date1.selecteddate = TimeArranged
time1.SelectedDate = TimeArranged.ToString("hh:mm")
date1 is a datepicker, time1 is a timepicker.
Thanks again,
Curt.
0
Accepted
Hello Curt,
You cannot set the SelectedDate property of the TimePicker to a string. Please try setting the property like this: time1.SelectedDate = TimeArranged. The control should ignore the date part and will take only the time. Additionally if you want to format the way the time is displayed, you should use the DateFormat property of the DateInput part of the picker like this: RadTimePicker1.DateInput.DateFormat = "hh:mm". See the following help article for reference on how to format dates with the DateFormat property.
Hope this helps.
Kind regards,
Pavel
the Telerik team
Instantly find answers to your questions at the new Telerik Support Center
You cannot set the SelectedDate property of the TimePicker to a string. Please try setting the property like this: time1.SelectedDate = TimeArranged. The control should ignore the date part and will take only the time. Additionally if you want to format the way the time is displayed, you should use the DateFormat property of the DateInput part of the picker like this: RadTimePicker1.DateInput.DateFormat = "hh:mm". See the following help article for reference on how to format dates with the DateFormat property.
Hope this helps.
Kind regards,
Pavel
the Telerik team
Instantly find answers to your questions at the new Telerik Support Center
0
Curt
Top achievements
Rank 1
answered on 21 May 2008, 08:38 AM
Thanks, thats worked great!