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

SchedulerBuilder

Defines the fluent interface for configuring the Scheduler.

Methods

Date(System.DateTime)

The current date of the scheduler. Used to determine the period which is displayed by the widget.

Parameters

date - System.DateTime

The Date

Example


            @(Html.Kendo().Scheduler<Kendo.Mvc.Examples.Models.Scheduler.Screening>()
                .Name("scheduler")
                .Date(new DateTime(2013, 6, 13))
                .BindTo(Model)
            )

Mobile()

Enables the adaptive rendering when viewed on mobile browser

Example


            @(Html.Kendo().Scheduler<Kendo.Mvc.Examples.Models.Scheduler.Screening>()
                .Name("scheduler")
                .Date(new DateTime(2013, 6, 13))
                .Mobile()
            )

Mobile(Kendo.Mvc.UI.MobileMode)

Used to determine if adaptive rendering should be used when viewed on mobile browser

Parameters

type - MobileMode

Example


            @(Html.Kendo().Scheduler<Kendo.Mvc.Examples.Models.Scheduler.Screening>()
                .Name("scheduler")
                .Date(new DateTime(2013, 6, 13))
                 .Mobile(MobileMode.Auto)
            )

StartTime(System.DateTime)

The start time of the week and day views. The scheduler will display events starting after the startTime.

Parameters

startTime - System.DateTime

The startTime.

Example


            @(Html.Kendo().Scheduler<Kendo.Mvc.Examples.Models.Scheduler.Screening>()
                .Name("scheduler")
                .Date(new DateTime(2013, 6, 13))
                .StartTime(new DateTime(2013, 6, 13, 10, 00, 00))
                .BindTo(Model)
            )

StartTime(System.Int32,System.Int32,System.Int32)

The start time of the week and day views. The scheduler will display events starting after the startTime.

Parameters

hours - System.Int32

The hours

minutes - System.Int32

The minutes

seconds - System.Int32

The seconds

Example


            @(Html.Kendo().Scheduler<Kendo.Mvc.Examples.Models.Scheduler.Screening>()
                .Name("scheduler")
                .Date(new DateTime(2013, 6, 13))
                .StartTime(10, 0, 0)
                .BindTo(Model)
            )

EndTime(System.DateTime)

The end time of the week and day views. The scheduler will display events ending before the endTime.

Parameters

endTime - System.DateTime

The endTime.

Example


            @(Html.Kendo().Scheduler<Kendo.Mvc.Examples.Models.Scheduler.Screening>()
                .Name("scheduler")
                .Date(new DateTime(2013, 6, 13))
                .EndTime(new DateTime(2013, 6, 13, 23, 00, 00))
                .BindTo(Model)
            )

EndTime(System.Int32,System.Int32,System.Int32)

The end time of the week and day views. The scheduler will display events ending before the endTime.

Parameters

hours - System.Int32

The hours

minutes - System.Int32

The minutes

seconds - System.Int32

The seconds

Example


            @(Html.Kendo().Scheduler<Kendo.Mvc.Examples.Models.Scheduler.Screening>()
                .Name("scheduler")
                .Date(new DateTime(2013, 6, 13))
                .EndTime(10,0,0)
                .BindTo(Model)
            )

WorkDayStart(System.DateTime)

The start time of the business day. The scheduler will display events starting after the workDayStart when the "Show Business Hours" button is pressed.

Parameters

workDayStart - System.DateTime

The workDayStart.

Example


            @(Html.Kendo().Scheduler<Kendo.Mvc.Examples.Models.Scheduler.Screening>()
                .Name("scheduler")
                .Date(new DateTime(2013, 6, 13))
                .WorkDayStart(new DateTime(2013, 6, 13, 10, 00, 00))
                .BindTo(Model)
            )

WorkDayStart(System.Int32,System.Int32,System.Int32)

The start time of the business day. The scheduler will display events starting after the workDayStart when the "Show Business Hours" button is pressed.

Parameters

hours - System.Int32

The hours

minutes - System.Int32

The minutes

seconds - System.Int32

The seconds

Example


            @(Html.Kendo().Scheduler<Kendo.Mvc.Examples.Models.Scheduler.Screening>()
                .Name("scheduler")
                .Date(new DateTime(2013, 6, 13))
                .WorkDayStart(10, 0, 0)
                .BindTo(Model)
            )

WorkDays(System.Int32[])

Sets the working days (index based).

Parameters

workDays - System.Int32[]

The indices of the days of the week

Example


            @(Html.Kendo().Scheduler<Kendo.Mvc.Examples.Models.Scheduler.Screening>()
                .Name("scheduler")
                .Date(new DateTime(2013, 6, 13))
                .WorkDays(new int[] { 1,3,4,5 })
                .BindTo(Model)
            )

WorkDayEnd(System.DateTime)

The end time of the business day. The scheduler will display events ending before the workDayEnd when the "Show Business Hours" button is pressed.

Parameters

workDayEnd - System.DateTime

The workDayEnd.

Example


            @(Html.Kendo().Scheduler<Kendo.Mvc.Examples.Models.Scheduler.Screening>()
                .Name("scheduler")
                .Date(new DateTime(2013, 6, 13))
                .WorkDayEnd(new DateTime(2013, 6, 13, 10, 00, 00))
                .BindTo(Model)
            )

WorkDayEnd(System.Int32,System.Int32,System.Int32)

The end time of the business day. The scheduler will display events ending before the workDayEnd when the "Show Business Hours" button is pressed.

Parameters

hours - System.Int32

The hours

minutes - System.Int32

The minutes

seconds - System.Int32

The seconds

Example


            @(Html.Kendo().Scheduler<Kendo.Mvc.Examples.Models.Scheduler.Screening>()
                .Name("scheduler")
                .Date(new DateTime(2013, 6, 13))
                .WorkDayEnd(16,0,0)
                .BindTo(Model)
            )

Height(System.Int32)

The height of the widget.

Parameters

height - System.Int32

The height.

Example


            @(Html.Kendo().Scheduler<Kendo.Mvc.Examples.Models.Scheduler.Screening>()
                .Name("scheduler")
                .Date(new DateTime(2013, 6, 13))
                .Height(600)
                .BindTo(Model)
            )

EventTemplate(System.String)

The template used to render the scheduler events.

Parameters

eventTemplate - System.String

The eventTemplate.

Example


            @(Html.Kendo().Scheduler<Kendo.Mvc.Examples.Models.Scheduler.Screening>()
                .Name("scheduler")
                .Date(new DateTime(2013, 6, 13))
                .StartTime(new DateTime(2013, 6, 13, 10, 00, 00))
                .EndTime(new DateTime(2013, 6, 13, 23, 00, 00))
                .Height(600)
                .EventTemplate(
                    "<div style='color:white'>" +
                        "<img src='" + Url.Content("~/Content/web/scheduler/") + "#= Image #' style='float:left'>" +
                        "<p>" +
                            "#: kendo.toString(Start, 'hh:mm') # - #: kendo.toString(End, 'hh:mm') #" +
                        "</p>" +
                        "<h3>#: title #</h3>" +
                            "<a href='#= Imdb #' style='color:white'>Movie in IMDB</a>" +
                    "</div>")
                .Views(views =>
                    {
                        views.DayView();
                        views.AgendaView();
                    })
                .BindTo(Model)
            )

EventTemplateId(System.String)

The Id of the template used to render the scheduler events.

Parameters

eventTemplateId - System.String

The eventTemplateId

Example


            @(Html.Kendo().Scheduler<Kendo.Mvc.Examples.Models.Scheduler.Screening>()
                .Name("scheduler")
                .Date(new DateTime(2013, 6, 13))
                .StartTime(new DateTime(2013, 6, 13, 10, 00, 00))
                .EndTime(new DateTime(2013, 6, 13, 23, 00, 00))
                .Height(600)
                .EventTemplateId("customEventTemplate")
                .Views(views =>
                    {
                        views.DayView();
                        views.AgendaView();
                    })
                .BindTo(Model)
            )

AllDayEventTemplate(System.String)

The template used to render the "all day" scheduler events.

Parameters

allDayEventTemplate - System.String

The allDayEventTemplate

Example


            @(Html.Kendo().Scheduler<Kendo.Mvc.Examples.Models.Scheduler.Screening>()
                .Name("scheduler")
                .AllDayEventTemplate("Template")
            )

AllDayEventTemplateId(System.String)

The Id of the template used to render the "all day" scheduler events.

Parameters

allDayEventTemplateId - System.String

The allDayEventTemplateId

Example


            @(Html.Kendo().Scheduler<Kendo.Mvc.Examples.Models.Scheduler.Screening>()
                .Name("scheduler")
                .AllDayEventTemplateId("TemplateID")
            )

GroupHeaderTemplate(System.String)

The template used to render the group headers of scheduler day, week, workWeek and timeline views.

Parameters

groupHeaderTemplate - System.String

The groupHeaderTemplate

Example


            @(Html.Kendo().Scheduler<Kendo.Mvc.Examples.Models.Scheduler.Screening>()
                .Name("scheduler")
                .GroupHeaderTemplate("Template")
            )

GroupHeaderTemplateId(System.String)

The Id of the template used to render the group headers of scheduler day, week, workWeek and timeline views.

Parameters

groupHeaderTemplateId - System.String

The groupHeaderTemplateId

Example


            @(Html.Kendo().Scheduler<Kendo.Mvc.Examples.Models.Scheduler.Screening>()
                .Name("scheduler")
                .GroupHeaderTemplate("TemplateID")
            )

AllDaySlot(System.Boolean)

If set to true the scheduler will display a slot for "all day" events.

Parameters

allDaySlot - System.Boolean

The allDaySlot.

Example


            @(Html.Kendo().Scheduler<Kendo.Mvc.Examples.Models.Scheduler.Screening>()
                .Name("scheduler")
                .AllDaySlot(true)
            )

ShowWorkHours(System.Boolean)

If set to true day and week views will be initially shown in business hours mode.

Parameters

value - System.Boolean

Example


            @(Html.Kendo().Scheduler<Kendo.Mvc.Examples.Models.Scheduler.Screening>()
                .Name("scheduler")
                .ShowWorkHours(true)
            )

ShowWorkHours()

If set to true day and week views will be initially shown in business hours mode.

Example


            @(Html.Kendo().Scheduler<Kendo.Mvc.Examples.Models.Scheduler.Screening>()
                .Name("scheduler")
                .ShowWorkHours(true)
            )

Selectable(System.Boolean)

If set to true the scheduler will enable the selection

Parameters

selectable - System.Boolean

The selectable.

Example


            @(Html.Kendo().Scheduler<Kendo.Mvc.Examples.Models.Scheduler.Screening>()
                .Name("scheduler")
                .Selectable(true)
            )

DateHeaderTemplate(System.String)

The template used to render the date header cells.

Parameters

dateHeaderTemplate - System.String

The dateHeaderTemplate

Example


            @(Html.Kendo().Scheduler<Kendo.Mvc.Examples.Models.Scheduler.Screening>()
                .Name("scheduler")
                .DateHeaderTemplate("Template")
            )

DateHeaderTemplateId(System.String)

The Id of the template used to render the date header cells.

Parameters

dateHeaderTemplateId - System.String

The dateHeaderTemplateId

Example


            @(Html.Kendo().Scheduler<Kendo.Mvc.Examples.Models.Scheduler.Screening>()
                .Name("scheduler")
                .Date(new DateTime(2013, 6, 13))
                .StartTime(new DateTime(2013, 6, 13, 10, 00, 00))
                .EndTime(new DateTime(2013, 6, 13, 23, 00, 00))
                .Height(600)
                .AllDayEventTemplateId("customAllDayTemplate")
                .Views(views =>
                    {
                        views.DayView();
                        views.AgendaView();
                    })
                .BindTo(Model)
            )

MajorTick(System.Int32)

The number of minutes represented by a major tick.

Parameters

majorTick - System.Int32

The majorTick

Example


            @(Html.Kendo().Scheduler<Kendo.Mvc.Examples.Models.Scheduler.Screening>()
                .Name("scheduler")
                .Date(new DateTime(2013, 6, 13))
                .Height(600)
                .MajorTick(120)
                .BindTo(Model)
            )

MajorTimeHeaderTemplate(System.String)

The template used to render the major ticks.

Parameters

majorTimeHeaderTemplate - System.String

The majorTimeHeaderTemplate

Example


            @(Html.Kendo().Scheduler<Kendo.Mvc.Examples.Models.Scheduler.Screening>()
                .Name("scheduler")
                .MajorTimeHeaderTemplate("Template")
            )

MajorTimeHeaderTemplateId(System.String)

The Id of the template used to render the major ticks.

Parameters

majorTimeHeaderTemplateId - System.String

The majorTimeHeaderTemplateId

Example


            @(Html.Kendo().Scheduler<Kendo.Mvc.Examples.Models.Scheduler.Screening>()
                .Name("scheduler")
                .MajorTimeHeaderTemplateId("TemplateID")
            )

MinorTickCount(System.Int32)

The number of time slots to display per major tick.

Parameters

minorTickCount - System.Int32

The minorTickCount

Example


            @(Html.Kendo().Scheduler<Kendo.Mvc.Examples.Models.Scheduler.Screening>()
                .Name("scheduler")
                .Date(new DateTime(2013, 7, 23))
                .Height(400)
                .MinorTickCount(1)
                .BindTo(Model)
            )

MinorTimeHeaderTemplate(System.String)

The template used to render the minor ticks.

Parameters

minorTimeHeaderTemplate - System.String

The minorTimeHeaderTemplate

Example


            @(Html.Kendo().Scheduler<Kendo.Mvc.Examples.Models.Scheduler.Screening>()
                .Name("scheduler")
                .MinorTimeHeaderTemplate("Template")
            )

MinorTimeHeaderTemplateId(System.String)

The Id of the template used to render the minor ticks.

Parameters

minorTimeHeaderTemplateId - System.String

The minorTimeHeaderTemplateId

Example


            @(Html.Kendo().Scheduler<Kendo.Mvc.Examples.Models.Scheduler.Screening>()
                .Name("scheduler")
                .MinorTimeHeaderTemplateId("TemplateID")
            )

Timezone(System.String)

The timezone which the scheduler will use to display the scheduler appointment dates. By default the current system timezone is used. This is an acceptable default when the scheduler widget is bound to local array of events. It is advisable to specify a timezone if the scheduler is bound to a remote service. That way all users would see the same dates and times no matter their configured system timezone. The complete list of the supported timezones is available in the List of IANA time zones Wikipedia page.

Parameters

timezone - System.String

The timezone

Example


            @(Html.Kendo().Scheduler<Kendo.Mvc.Examples.Models.Scheduler.Task>()
                .Name("scheduler")
                .Date(new DateTime(2013, 6, 13))
                .Timezone("Europe/London")
                .Height(600)
                .DataSource(d => d
                    .Model(m => m.Id(f => f.TaskID))
                        .Read("Read", "Scheduler")
                        .Create("Create", "Scheduler")
                        .Destroy("Destroy", "Scheduler")
                        .Update("Update", "Scheduler")
                )
            )

Width(System.Int32)

The width of the widget.

Parameters

width - System.Int32

The width

Example


            @(Html.Kendo().Scheduler<Kendo.Mvc.Examples.Models.Scheduler.Task>()
                .Name("scheduler")
                .Date(new DateTime(2013, 6, 13))
                .Width(800)
                .Height(600)
                .DataSource(d => d
                    .Model(m => m.Id(f => f.TaskID))
                        .Read("Read", "Scheduler")
                        .Create("Create", "Scheduler")
                        .Destroy("Destroy", "Scheduler")
                        .Update("Update", "Scheduler")
                )
            )

Snap(System.Boolean)

If set to false the events would not snap events to the nearest slot during dragging (resizing or moving). Set it to false to allow free moving and resizing of events.

Parameters

isSnapable - System.Boolean

The isSnapable

Example


            @(Html.Kendo().Scheduler<Kendo.Mvc.Examples.Models.Scheduler.Task>()
                .Name("scheduler")
                .Date(new DateTime(2013, 6, 13))
                .Snap(false)
                .DataSource(d => d
                    .Model(m => m.Id(f => f.TaskID))
                        .Read("Read", "Scheduler")
                        .Create("Create", "Scheduler")
                        .Destroy("Destroy", "Scheduler")
                        .Update("Update", "Scheduler")
                )
            )

AutoBind(System.Boolean)

If set to false the initial binding will be prevented.

Parameters

autoBind - System.Boolean

The autoBind

Example


            @(Html.Kendo().Scheduler<Kendo.Mvc.Examples.Models.Scheduler.Task>()
                .Name("scheduler")
                .Date(new DateTime(2013, 6, 13))
                .AutoBind(false)
                .DataSource(d => d
                    .Model(m => m.Id(f => f.TaskID))
                        .Read("Read", "Scheduler")
                )
            )

WorkWeekStart(System.Int32)

Sets the start day of work week by index.

Parameters

workWeekStartDay - System.Int32

The workWeekStartDay

Example


            @(Html.Kendo().Scheduler<Kendo.Mvc.Examples.Models.Scheduler.Task>()
                .Name("scheduler")
                .Date(new DateTime(2013, 6, 13))
                .WorkWeekStart(2)
                .DataSource(d => d
                    .Model(m => m.Id(f => f.TaskID))
                        .Read("Read", "Scheduler")
                )
            )

WorkWeekEnd(System.Int32)

Sets the end day of work week by index.

Parameters

workWeekEndDay - System.Int32

The workWeekEndDay

Example


            @(Html.Kendo().Scheduler<Kendo.Mvc.Examples.Models.Scheduler.Task>()
                .Name("scheduler")
                .Date(new DateTime(2013, 6, 13))
                .WorkWeekEnd(2)
                .DataSource(d => d
                    .Model(m => m.Id(f => f.TaskID))
                        .Read("Read", "Scheduler")
                )
            )

Editable(System.Action)

Sets the editing configuration of the scheduler.

Parameters

configurator - System.Action<SchedulerEditableSettingsBuilder>

The lambda which configures the editing

Example


            @(Html.Kendo().Scheduler<Kendo.Mvc.Examples.Models.Scheduler.Task>()
                .Name("scheduler")
                .Date(new DateTime(2013, 6, 13))
                .Editable(editable =>
                {
                    editable.Confirmation(false);
                    editable.TemplateId("customEditTemplate");
                })
                .DataSource(d => d
                    .Model(m => m.Id(f => f.TaskID))
                        .Read("Read", "Scheduler")
                        .Create("Create", "Scheduler")
                        .Destroy("Destroy", "Scheduler")
                        .Update("Update", "Scheduler")
                )
            )

Editable(System.Boolean)

If set to false the user would not be able to create new scheduler events and modify or delete existing ones.

Parameters

isEditable - System.Boolean

The isEditable

Example


            @(Html.Kendo().Scheduler<Kendo.Mvc.Examples.Models.Scheduler.Task>()
                .Name("scheduler")
                .Date(new DateTime(2013, 6, 13))
                .Editable(false)
                .DataSource(d => d
                    .Model(m => m.Id(f => f.TaskID))
                        .Read("Read", "Scheduler")
                )
            )

Footer(System.Action)

If set to false the footer of the scheduler would not be displayed.

Parameters

configurator - System.Action<SchedulerFooterBuilder>

The configurator for the footer setting.

Example


            @(Html.Kendo().Scheduler<Kendo.Mvc.Examples.Models.Scheduler.Screening>()
                .Name("scheduler")
                .Footer(f=>f.Command("command"))
            )

Footer(System.Boolean)

If set to false the footer of the scheduler would not be displayed.

Parameters

enabled - System.Boolean

Enables or disables the footer option.

Example


            @(Html.Kendo().Scheduler<Kendo.Mvc.Examples.Models.Scheduler.Screening>()
                .Name("scheduler")
                .Footer(false)
            )

Min(System.DateTime)

Constraints the minimum date which can be selected via the scheduler navigation.

Parameters

date - System.DateTime

The min date

Example


            @(Html.Kendo().Scheduler<Kendo.Mvc.Examples.Models.Scheduler.Screening>()
                .Name("scheduler")
                .Min(DateTime.Now)
            )

Max(System.DateTime)

Constraints the maximum date which can be selected via the scheduler navigation.

Parameters

date - System.DateTime

The max date

Example


            @(Html.Kendo().Scheduler<Kendo.Mvc.Examples.Models.Scheduler.Screening>()
                .Name("scheduler")
                .Max(DateTime.Now)
            )

Group(System.Action)

Sets the resources grouping configuration of the scheduler.

Parameters

configuration - System.Action<SchedulerGroupBuilder>

The lambda which configures the scheduler grouping

Example


            @(Html.Kendo().Scheduler<Task>()
               .Name("Scheduler")
               .Resources(resource =>
               {
                   resource.Add(m => m.TaskID)
                       .Title("Color")
                       .Multiple(true)
                       .DataTextField("Text")
                       .DataValueField("Value")
                       .DataSource(d => d.Read("Attendies", "Scheduler"));
               })
               .DataSource(dataSource => dataSource
                   .Model(m => m.Id(f => f.TaskID))
               ))

Resources(System.Action)

Sets the resources configuration of the scheduler.

Parameters

addResourceAction - System.Action<SchedulerResourceFactory>

The lambda which configures the scheduler resources

Example


            @(Html.Kendo().Scheduler<Task>()
               .Name("Scheduler")
               .Resources(resource =>
               {
                   resource.Add(m => m.TaskID)
                       .Title("Color")
                       .Multiple(true)
                       .DataTextField("Text")
                       .DataValueField("Value")
                       .DataSource(d => d.Read("Attendies", "Scheduler"));
               })
               .DataSource(dataSource => dataSource
                   .Model(m => m.Id(f => f.TaskID))
               ))

Views(System.Action)

Sets the views configuration of the scheduler.

Parameters

addViewAction - System.Action<SchedulerViewFactory>

The lambda which configures the scheduler views

Example


            @(Html.Kendo().Scheduler<Kendo.Mvc.Examples.Models.Scheduler.Task>()
                .Name("scheduler")
                .Date(new DateTime(2013, 6, 13))
                .Views(views => {
                    views.DayView();
                    views.AgendaView();
                })
                .BindTo(Model)
            )

Messages(System.Action)

Sets the messages of the scheduler.

Parameters

addViewAction - System.Action<SchedulerMessagesBuilder>

The lambda which configures the scheduler messages

Example


            @(Html.Kendo().Scheduler<Kendo.Mvc.Examples.Models.Scheduler.Screening>()
                .Name("scheduler")
                .Messages(m=>m.AllDay("all day"))
            )

Events(System.Action)

Sets the events configuration of the scheduler.

Parameters

clientEventsAction - System.Action<SchedulerEventBuilder>

The lambda which configures the scheduler events

Example


             @( Html.Kendo().Scheduler<Task>()
                        .Name("Scheduler")
                        .Events(events =>
                            events.Remove("remove")
                        )
                        .BindTo(Model)
            )

BindTo(System.Collections.Generic.IEnumerable)

Binds the scheduler to a list of objects

Parameters

dataSource - System.Collections.Generic.IEnumerable<TModel>

The data source.

Example


            @model IEnumerable<Task>
            @(Html.Kendo().Scheduler<Task>()
               .Name("Scheduler")
               .BindTo(Model)
               .DataSource(dataSource => dataSource
                   .Model(m => m.Id(f => f.TaskID))
               ))

DataSource(System.Action)

Configures the DataSource options.

Parameters

configurator - System.Action<SchedulerAjaxDataSourceBuilder>

The DataSource configurator action.

Example


             @( Html.Kendo().Scheduler<Task>()
                        .Name("Scheduler")
                        .DataSource(source =>
                        {
                            source.Read(read =>
                            {
                                read.Action("Read", "Scheduler");
                            });
                        })
            )

CurrentTimeMarker(System.Action)

Sets the currentTimeMarker configuration of the scheduler.

Parameters

configurator - System.Action<SchedulerCurrentTimeMarkerSettingsBuilder>

The lambda which configures the currentTimeMarker

Example


            @(Html.Kendo().Scheduler<Kendo.Mvc.Examples.Models.Scheduler.Task>()
                .Name("scheduler")
                .Date(new DateTime(2013, 6, 13))
                .CurrentTimeMarker(marker =>
                {
                    marker.UpdateInterval(100);
                    marker.UseLocalTimezone(false);
                })
                .DataSource(d => d
                    .Model(m => m.Id(f => f.TaskID))
                        .Read("Read", "Scheduler")
                        .Create("Create", "Scheduler")
                        .Destroy("Destroy", "Scheduler")
                        .Update("Update", "Scheduler")
                )
            )

CurrentTimeMarker(System.Boolean)

If set to false the "current time" marker would be disabled.

Parameters

enabled - System.Boolean

The enabled

Example


            @(Html.Kendo().Scheduler<Kendo.Mvc.Examples.Models.Scheduler.Task>()
                .Name("scheduler")
                .Date(new DateTime(2013, 6, 13))
                .CurrentTimeMarker(false)
                .DataSource(d => d
                    .Model(m => m.Id(f => f.TaskID))
                        .Read("Read", "Scheduler")
                )
            )

Pdf(System.Action)

Configures the PDF export settings.

Parameters

configurator - System.Action<PDFSettingsBuilder>

Example


            @(Html.Kendo().Scheduler<Task>()
                .Name("scheduler")
                .Pdf(pdf => pdf.FileName("SchedulerExport.pdf"))
                .DataSource(dataSource =>
                    // configure the data source
                    dataSource
                        .Ajax()
                        .Read("Read", "Scheduler")
                )
            )

Toolbar(System.Action)

Adds PDF command to the toolbar.

Parameters

addToolbarAction - System.Action<SchedulerToolbarFactory>

Example


            @(Html.Kendo().Scheduler<Task>()
                .Name("scheduler")
                .Toolbar(toolbar => toolbar.Pdf())
                .Pdf(pdf => pdf.FileName("SchedulerExport.pdf"))
                .DataSource(dataSource =>
                    // configure the data source
                    dataSource
                        .Ajax()
                        .Read("Read", "Scheduler")
                )
            )

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>

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?