Telerik UI for Windows 8 HTML

This article describes the events of RadDatePicker and RadTimePicker and their most notable event arguments.

Both RadDatePicker and RadTimePicker have the same set of events with identical event arguments.

Events

Event Name

Description

Arguments

change

Fires when the date/time is changed via the selector.

e.target: The RadDatePicker/RadTimePicker control whose selection has changed. The new value can be accessed through e.target.value.

close

Fires after the selector popup closes.

e.target: The RadDatePicker/RadTimePicker control which has been closed.

open

Fires after the selector popup opens.

e.target: The RadDatePicker/RadTimePicker control which has been opened.

Below you can see a sample where the change event is handled to access the new picker value:

HTML Copy imageCopy
<div id="myPicker" data-win-control="Telerik.UI.RadDatePicker" data-win-options="{
            onchange: Sample.Helpers.change
        }">
</div>
<br />
<p id="dateInfo" style="color: #336699"></p>
JavaScript Copy imageCopy
WinJS.Namespace.define("Sample.Helpers", {
    change: WinJS.Utilities.markSupportedForProcessing(function (e) {
        document.getElementById("dateInfo").innerText = "Selected date: " + e.target.value;
    })
});