RadTimeline for ASP.NET AJAX is based on the Kendo UI Timeline Widget. Thus, it exposes the Client-side API and methods offered by the widget and mainly provides a wrapper and API for working with the Timeline on the server.
You can get Client-side object reference to the Timeline control in order to use its API like this:
var
radTimelineObject = $find(
"<%=RadTimeline1.ClientID %>"
);
The most commonly used RadTimeline client-side methods are:
-
get_orientation—Returns the orienation of the timeline axis.
-
open—Opens event details in horizontal mode.
-
expand—Expands an event in vertical mode.
-
collapse—Toggles the readonly state of the widget. When the widget is readonly it doesn't allow user input.
-
previous—Closes the widget popup.
-
next—Opens or closes the widget popup.
You can find the full client-side API of the control in the RadTimeline Client-side API documentation article.
Get Client-side Object Reference to the Kendo Timeline widget in order to use its API
There are two ways to get a reference to the Kendo Timeline widget in order to use its API:
-
Use the get_kendoWidget method the RadTimeline client-side object exposes. You can get the RadTimeline object through the $find() MS AJAX method:
var
radTimelineObject = $find(
"<%=RadTimeline1.ClientID %>"
);
//the standard script control object
var
kendoTimelineObject = radTimelineObject.get_kendoWidget();
//the Kendo widget
-
Use the standard Kendo approach for getting the widget through the data-attributes of the DOM element:
var
kendoTimelineObject = $telerik.$(
"#<%=RadTimeline1.ClientID %>"
).data(
"kendoTimeline"
);
//the jQuery selector must get the RadTimeline1 select element