Product Bundles
DevCraft
All Telerik .NET tools and Kendo UI JavaScript components in one package. Now enhanced with:
Web
Mobile
Document Management
Desktop
Reporting
Testing & Mocking
CMS
UI/UX Tools
Debugging
Free Tools
Support and Learning
Productivity and Design Tools
<
telerik:RadDateTimePicker
ID
=
"RadDateTimePicker1"
runat
"server"
>
TimeView
"TimeView1"
TimeTemplate
HH:
asp:DropDownList
"HoursDropDownList"
asp:ListItem
Text
"1"
/>
"2"
"3"
</
mm:
"MinutesDropDownList"
br
asp:Button
"Button1"
OnClientClick
"return ApplyTime()"
"Apply Time"
<script type=
"text/javascript"
Sys.Application.add_load(clearClickHandler);
function
clearClickHandler() {
var
tv = $find(
"<%= RadDateTimePicker1.ClientID %>"
).get_timeView();
if
(tv._onCellMouseOutDelegate) {
$removeHandler(tv.DivElement,
"mouseout"
, tv._onCellMouseOutDelegate);
tv._onCellMouseOutDelegate =
null
;
}
(tv._onCellMouseOverDelegate) {
"mouseover"
, tv._onCellMouseOverDelegate);
tv._onCellMouseOverDelegate =
(tv._onCellClickDelegate) {
"click"
, tv._onCellClickDelegate);
tv._onCellClickDelegate =
ApplyTime() {
picker = $find(
);
picker.hideTimePopup();
pd = picker.get_selectedDate();
(!pd) {
pd =
new
Date();
pd.setHours(parseInt($get(
"<%= RadDateTimePicker1.ClientID %>_timeView_tdl_ctl01_HoursDropDownList"
).value));
pd.setMinutes(parseInt($get(
"<%= RadDateTimePicker1.ClientID %>_timeView_tdl_ctl01_MinutesDropDownList"
picker.set_selectedDate(pd);
return
false
</script>
protected
void
Page_Load(
object
sender, EventArgs e)
{
RadDateTimePicker1.TimeView.DataList.DataSource =
DateTime[1];
RadDateTimePicker1.TimeView.DataList.DataBind();