New to Telerik UI for ASP.NET MVC? Download free 30-day trial

TimelineBuilder

Methods

DataSource(System.Action)

Sets the data source configuration of the timeline.

Parameters

configurator - System.Action<TimelineReadOnlyDataSourceBuilder>

The lambda which configures the data source

Example


            @(Html.Kendo().Timeline<Event>()
                .Name("timeline")
                .DataSource(dataSource =>
                    // configure the data source
                    dataSource
                        .Ajax()
                        .Read(read => read.Action("Events_Read", "Home"))
                )
            )

DataSource(System.String)

Sets the ID of the DataSource widget used by the Timeline.

Parameters

dataSourceId - System.String

The id of the DataSource

Example


            @(Html.Kendo().Timeline<Event>()
                .Name("timeline")
                .DataSource("dataSource")
            )

AutoBind(System.Boolean)

If set to false, the Timeline will not bind to the data source during initialization, i.e. it will not call the fetch method of the dataSource instance. In such scenarios data binding will occur when the change event of the dataSource instance is fired. By default, autoBind is set to true and the widget will bind to the data source specified in the configuration.

Parameters

value - System.Boolean

The value that configures the autobind.

AlternatingMode(System.Boolean)

Indicates whether events should be positioned on both sides of the timeline axis. By default all events are displayed on the right side of the timeline axis.

Parameters

value - System.Boolean

The value that configures the alternatingmode.

CollapsibleEvents(System.Boolean)

Enables the events in the Kendo UI Timeline to be expandable or collapsible. When enabled initially all events are collapsed.

Parameters

value - System.Boolean

The value that configures the collapsibleevents.

DataActionsField(System.String)

Sets the field of the data item that provides the actions information for the event.

Parameters

value - System.String

The value that configures the dataactionsfield.

DataDescriptionField(System.String)

Sets the field of the data item that provides the description information for the event.

Parameters

value - System.String

The value that configures the datadescriptionfield.

DataDateField(System.String)

Sets the field of the data item that provides information when the given event happened in time.

Parameters

value - System.String

The value that configures the datadatefield.

DataImagesAltField(System.String)

Sets the field of the data item that provides the value for the alt attribute of the images.

Parameters

value - System.String

The value that configures the dataimagesaltfield.

DataImagesField(System.String)

Sets the field of the data item that provides the images information for the event.

Parameters

value - System.String

The value that configures the dataimagesfield.

DataSubtitleField(System.String)

Sets the field of the data item that provides the subtitle information for the event.

Parameters

value - System.String

The value that configures the datasubtitlefield.

DataTitleField(System.String)

Sets the field of the data item that provides the title information for the event.

Parameters

value - System.String

The value that configures the datatitlefield.

EventTemplate(System.String)

Specifies the template used to render the event details.

Parameters

value - System.String

The value that configures the eventtemplate.

EventTemplateId(System.String)

Specifies the template used to render the event details.

Parameters

value - System.String

The value that configures the eventtemplate.

EventTemplateView(System.Web.Mvc.MvcHtmlString)

Specifies the template used to render the event details.

Parameters

value - System.Web.Mvc.MvcHtmlString

The value that configures the eventtemplate.

EventTemplateHandler(System.String)

Specifies the template used to render the event details.

Parameters

value - System.String

The value that configures the eventtemplate.

EventTemplate(Kendo.Mvc.UI.TemplateBuilder)

Specifies the template used to render the event details.

Parameters

template - TemplateBuilder<TModel>

A Template component that configures the eventtemplate.

DateFormat(System.String)

Sets the date format used to display the date in the event's label

Parameters

value - System.String

The value that configures the dateformat.

EventHeight(System.Double)

Sets specific height for the event in horizontal mode.

Parameters

value - System.Double

The value that configures the eventheight.

EventWidth(System.Double)

Sets specific width for the event in vertical mode.

Parameters

value - System.Double

The value that configures the eventwidth.

If set to true, will enable the keyboard navigation for the component.

Parameters

value - System.Boolean

The value that configures the navigatable.

ShowDateLabels(System.Boolean)

If set to false, the event's date label will be hidden.

Parameters

value - System.Boolean

The value that configures the showdatelabels.

Orientation(Kendo.Mvc.UI.TimelineOrientation)

Defines the orientation of the Timeline widget

Parameters

value - TimelineOrientation

The value that configures the orientation.

AlternatingMode()

Indicates whether events should be positioned on both sides of the timeline axis. By default all events are displayed on the right side of the timeline axis.

CollapsibleEvents()

Enables the events in the Kendo UI Timeline to be expandable or collapsible. When enabled initially all events are collapsed.

Events(System.Action)

Configures the client-side events.

Parameters

configurator - System.Action<TimelineEventBuilder>

The client events action.

Example


             @( Html.Kendo().Timeline()
                        .Name("Timeline")
                        .Events(events => events
                            .Change("onChange")
                        )
            )

ToComponent()

Returns the internal view component.

Name(System.String)

Sets the name of the component.

Parameters

componentName - System.String

The name of the component.

Example


            @(Html.Kendo().Grid<OrderViewModel>()
               .Name("grid")
               .Columns(columns =>
               {
                   columns.Bound(p => p.OrderID).Filterable(false);
                   columns.Bound(p => p.Freight);  
               })
               .DataSource(dataSource => dataSource
                   .Ajax()
                   .PageSize(20)
                   .Read(read => read.Action("Orders_Read", "Grid"))
               )
            )

Deferred(System.Boolean)

Suppress initialization script rendering. Note that this options should be used in conjunction with Kendo.Mvc.UI.Fluent.WidgetFactory.DeferredScripts(System.Boolean)

Parameters

deferred - System.Boolean

ModelMetadata(System.Web.Mvc.ModelMetadata)

Uses the Metadata of the Model.

Parameters

modelMetadata - System.Web.Mvc.ModelMetadata

The metadata set for the Model

HtmlAttributes(System.Object)

Sets the HTML attributes.

Parameters

attributes - System.Object

The HTML attributes.

HtmlAttributes(System.Collections.Generic.IDictionary)

Parameters

attributes - System.Collections.Generic.IDictionary<String,Object>

AsChildComponent()

Render()

Renders the component.

Example


            @(@Page Inherits="System.Web.Mvc.ViewPage<IEnumerable<Product>>" )
            @( Html.Kendo().Grid(Model)
                .Name("grid")
                .DetailTemplate(product => {
                    )
                       Product Details:
                       <div>Product Name: @( product.ProductName )</div>
                       <div>Units In Stock: @( product.UnitsInStock )</div>
                    @(
                })
                .Render();
            )

ToHtmlString()

ToClientTemplate()

In this article
Not finding the help you need?