SchedulerBuilder

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

Razor
 
            @(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

Razor
 
            @(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

Razor
 
            @(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

Razor
 
            @(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

Razor
 
            @(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

Razor
 
            @(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

Razor
 
            @(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

Razor
 
            @(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

Razor
 
            @(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

Razor
 
            @(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

Razor
 
            @(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

Razor
 
            @(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

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

EventTemplate(System.String)

Defines the template used to render the Scheduler events. The available fields in the template are: - description: The event description. - end: The event end date. - resources: The event resources. - start: The event start date. - title: The event title.

Parameters

eventTemplate - System.String

The value that configures the template content.

Example

Razor
 
            @(Html.Kendo().Scheduler<Kendo.Mvc.Examples.Models.Scheduler.Screening>()
            	.Name("scheduler")
            	.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>"
            	)
            )
             

EventTemplateId(System.String)

Defines the template used to render the Scheduler events. The available fields in the template are: - description: The event description. - end: The event end date. - resources: The event resources. - start: The event start date. - title: The event title.

Parameters

eventTemplateId - System.String

The "id" attribute of the external Kendo UI Template.

Example

Razor
 
            @(Html.Kendo().Scheduler<Kendo.Mvc.Examples.Models.Scheduler.Screening>()
            	.Name("scheduler")
            	.EventTemplateId("customEventTemplate")
            )
             

EventTemplateView(System.Web.Mvc.MvcHtmlString)

Defines the template used to render the Scheduler events. The available fields in the template are: - description: The event description. - end: The event end date. - resources: The event resources. - start: The event start date. - title: The event title.

Parameters

eventTemplate - System.Web.Mvc.MvcHtmlString

The Razor View that contains the template.

Example

Razor
 
            @(Html.Kendo().Scheduler<Kendo.Mvc.Examples.Models.Scheduler.Screening>()
            	.Name("scheduler")
            	.EventTemplateView(Html.Partial("EventTemplateView"))
            )
             

EventTemplateHandler(System.String)

Defines the template used to render the Scheduler events. The available fields in the template are: - description: The event description. - end: The event end date. - resources: The event resources. - start: The event start date. - title: The event title.

Parameters

eventTemplate - System.String

The JavaScript function that returns the template.

Example

Razor
 
            @(Html.Kendo().Scheduler<Screening>()
            	.Name("scheduler")
            	.EventTemplateHandler("getEventTemplate")
            )
            <script>
                function getEventTemplate(data) {
                    return `<div>Title: ${data.title} </div>`;
                }
            </script>
             

EventTemplate(Kendo.Mvc.UI.Fluent.TemplateBuilder)

Defines the template used to render the Scheduler events. The available fields in the template are: - description: The event description. - end: The event end date. - resources: The event resources. - start: The event start date. - title: The event title.

Parameters

template - TemplateBuilder<T>

A Template component that configures the template.

Example

Razor
 
            @(Html.Kendo().Scheduler<Screening>()
            	.Name("scheduler")
            	.EventTemplate(Html.Kendo().Template().AddHtml("<div>Title: ${data.title} </div>"))
            )
             

AllDayEventTemplate(System.String)

Defines the template used to render the "all day" Scheduler events. The available fields in the template are: - description: The event description. - end: The event end date. - isAllDay: if "true", the event is all day. - resources: The event resources collection. - start: The event start date. - title: The event title.

Parameters

allDayEventTemplate - System.String

The value that configures the template content.

Example

Razor
 
            @(Html.Kendo().Scheduler<Kendo.Mvc.Examples.Models.Scheduler.Screening>()
                .Name("scheduler")
                .AllDayEventTemplate("<h3>#: title #</h3>")
            )
             

AllDayEventTemplateId(System.String)

Defines the template used to render the "all day" Scheduler events. The available fields in the template are: - description: The event description. - end: The event end date. - isAllDay: if "true", the event is all day. - resources: The event resources collection. - start: The event start date. - title: The event title.

Parameters

allDayEventTemplateId - System.String

The "id" attribute of the external Kendo UI Template.

Example

Razor
 
            @(Html.Kendo().Scheduler<Kendo.Mvc.Examples.Models.Scheduler.Screening>()
                .Name("scheduler")
                .AllDayEventTemplateId("allDayTemplate")
            )
            <script id="allDayTemplate" type="text/x-kendo-template">
                <h3>#: title #</h3>
            </script>
             

AllDayEventTemplateView(System.Web.Mvc.MvcHtmlString)

Defines the template used to render the "all day" Scheduler events. The available fields in the template are: - description: The event description. - end: The event end date. - isAllDay: if "true", the event is all day. - resources: The event resources collection. - start: The event start date. - title: The event title.

Parameters

allDayEventTemplate - System.Web.Mvc.MvcHtmlString

The Razor View that contains the template.

Example

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

AllDayEventTemplateHandler(System.String)

Defines the template used to render the "all day" Scheduler events. The available fields in the template are: - description: The event description. - end: The event end date. - isAllDay: if "true", the event is all day. - resources: The event resources collection. - start: The event start date. - title: The event title.

Parameters

allDayEventTemplate - System.String

The JavaScript function that returns the template.

Example

Razor
 
            @(Html.Kendo().Scheduler<Kendo.Mvc.Examples.Models.Scheduler.Screening>()
                .Name("scheduler")
                .AllDayEventTemplateHandler("getAllDayEventTemplate")
            )
            <script>
                function getAllDayEventTemplate(data) {
                    return `<h3>${data.title}</h3>`;
                }
            </script>
             

AllDayEventTemplate(Kendo.Mvc.UI.Fluent.TemplateBuilder)

Defines the template used to render the "all day" Scheduler events. The available fields in the template are: - description: The event description. - end: The event end date. - isAllDay: if "true", the event is all day. - resources: The event resources collection. - start: The event start date. - title: The event title.

Parameters

template - TemplateBuilder<T>

A Template component that configures the template.

Example

Razor
 
            @(Html.Kendo().Scheduler<Kendo.Mvc.Examples.Models.Scheduler.Screening>()
                .Name("scheduler")
                .AllDayEventTemplate(Html.Kendo().Template().AddHtml("<h3>${data.title}</h3>"))
            )
             

GroupHeaderTemplate(System.String)

Defines the template used to render the group headers of the Scheduler Day, Week, WorkWeek, and Timeline views. The available fields in the template are: - text: The group text. - color: The group color. - value: The group value. - field: The field of the event, which contains the resource id. - title: The 'title' option of the resource. - name: The 'name' option of the resource.

Parameters

groupHeaderTemplate - System.String

The value that configures the template content.

Example

Razor
 
            @(Html.Kendo().Scheduler<Kendo.Mvc.Examples.Models.Scheduler.Screening>()
                .Name("scheduler")
                .GroupHeaderTemplate("<strong style='color: #=color#'>#: text #</strong>")
            )
             

GroupHeaderTemplateId(System.String)

Defines the template used to render the group headers of the Scheduler Day, Week, WorkWeek, and Timeline views. The available fields in the template are: - text: The group text. - color: The group color. - value: The group value. - field: The field of the event, which contains the resource id. - title: The 'title' option of the resource. - name: The 'name' option of the resource.

Parameters

groupHeaderTemplateId - System.String

The "id" attribute of the external Kendo UI Template.

Example

Razor
 
            @(Html.Kendo().Scheduler<Kendo.Mvc.Examples.Models.Scheduler.Screening>()
                .Name("scheduler")
                .GroupHeaderTemplateId("groupHeaderTemplate")
            )
            <script id="groupHeaderTemplate" type="text/x-kendo-template">
                <strong style='color: #=color#'>#: text #</strong>
            </script>
             

GroupHeaderTemplateView(System.Web.Mvc.MvcHtmlString)

Defines the template used to render the group headers of the Scheduler Day, Week, WorkWeek, and Timeline views. The available fields in the template are: - text: The group text. - color: The group color. - value: The group value. - field: The field of the event, which contains the resource id. - title: The 'title' option of the resource. - name: The 'name' option of the resource.

Parameters

groupHeaderTemplate - System.Web.Mvc.MvcHtmlString

The Razor View that contains the template.

Example

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

GroupHeaderTemplateHandler(System.String)

Defines the template used to render the group headers of the Scheduler Day, Week, WorkWeek, and Timeline views. The available fields in the template are: - text: The group text. - color: The group color. - value: The group value. - field: The field of the event, which contains the resource id. - title: The 'title' option of the resource. - name: The 'name' option of the resource.

Parameters

groupHeaderTemplate - System.String

The JavaScript function that returns the template.

Example

Razor
 
            @(Html.Kendo().Scheduler<Activity>()
                .Name("scheduler")
                .GroupHeaderTemplateHandler("getGroupHeaderTemplate")
            )
            <script>
                function getGroupHeaderTemplate(data) {
                    return `<strong style='color: ${data.color}'>${data.text}</strong>`;
                }
            </script>
             

GroupHeaderTemplate(Kendo.Mvc.UI.Fluent.TemplateBuilder)

Defines the template used to render the group headers of the Scheduler Day, Week, WorkWeek, and Timeline views. The available fields in the template are: - text: The group text. - color: The group color. - value: The group value. - field: The field of the event, which contains the resource id. - title: The 'title' option of the resource. - name: The 'name' option of the resource.

Parameters

template - TemplateBuilder<T>

A Template component that configures the template.

Example

Razor
 
            @(Html.Kendo().Scheduler<Activity>()
                .Name("scheduler")
                .GroupHeaderTemplate(Html.Kendo().Template().AddHtml("<strong style='color: ${data.color}'>${data.text}</strong>"))
            )
             

AllDaySlot(System.Boolean)

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

Parameters

allDaySlot - System.Boolean

The allDaySlot.

Example

Razor
 
            @(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

Razor
 
            @(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

Razor
 
            @(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

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

DateHeaderTemplate(System.String)

Defines the template used to render the date header cells. By default, the Scheduler renders the date using a custom date format - "ddd M/dd". The "ddd" specifier represents the abbreviated name of the weekday and will be localized based on the current Kendo UI culture. To control the day and month order, use a custom template. The available field in the template is "date", which represents the major tick date.

Parameters

dateHeaderTemplate - System.String

The value that configures the template content.

Example

Razor
 
            @(Html.Kendo().Scheduler<Kendo.Mvc.Examples.Models.Scheduler.Screening>()
                .Name("scheduler")
                .DateHeaderTemplate("<strong>#=kendo.toString(date, 'd')#</strong>")
            )
             

DateHeaderTemplateId(System.String)

Defines the template used to render the date header cells. By default, the Scheduler renders the date using a custom date format - "ddd M/dd". The "ddd" specifier represents the abbreviated name of the weekday and will be localized based on the current Kendo UI culture. To control the day and month order, use a custom template. The available field in the template is "date", which represents the major tick date.

Parameters

dateHeaderTemplateId - System.String

The "id" attribute of the external Kendo UI Template.

Example

Razor
 
            @(Html.Kendo().Scheduler<Kendo.Mvc.Examples.Models.Scheduler.Screening>()
                .Name("scheduler")
                .DateHeaderTemplateId("dateHeaderTemplate")
            )
            <script id="dateHeaderTemplate" type="text/x-kendo-template">
                <strong>#=kendo.toString(date, 'd')#</strong>
            </script>
             

DateHeaderTemplateView(System.Web.Mvc.MvcHtmlString)

Defines the template used to render the date header cells. By default, the Scheduler renders the date using a custom date format - "ddd M/dd". The "ddd" specifier represents the abbreviated name of the weekday and will be localized based on the current Kendo UI culture. To control the day and month order, use a custom template. The available field in the template is "date", which represents the major tick date.

Parameters

dateHeaderTemplate - System.Web.Mvc.MvcHtmlString

The Razor View that contains the template.

Example

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

DateHeaderTemplateHandler(System.String)

Defines the template used to render the date header cells. By default, the Scheduler renders the date using a custom date format - "ddd M/dd". The "ddd" specifier represents the abbreviated name of the weekday and will be localized based on the current Kendo UI culture. To control the day and month order, use a custom template. The available field in the template is "date", which represents the major tick date.

Parameters

dateHeaderTemplate - System.String

The JavaScript function that returns the template.

Example

Razor
 
            @(Html.Kendo().Scheduler<Activity>()
                .Name("scheduler")
                .DateHeaderTemplateHandler("getDateHeaderTemplate")
            )
            <script>
                function getDateHeaderTemplate(data) {
                    return `<strong>${kendo.toString(data.date, 'd')}</strong>`;
                }
            </script>
             

DateHeaderTemplate(Kendo.Mvc.UI.Fluent.TemplateBuilder)

Defines the template used to render the date header cells. By default, the Scheduler renders the date using a custom date format - "ddd M/dd". The "ddd" specifier represents the abbreviated name of the weekday and will be localized based on the current Kendo UI culture. To control the day and month order, use a custom template. The available field in the template is "date", which represents the major tick date.

Parameters

template - TemplateBuilder<TModel>

A Template component that configures the template.

Example

Razor
 
            @(Html.Kendo().Scheduler<Activity>()
                .Name("scheduler")
                .DateHeaderTemplate(Html.Kendo().Template().AddHtml("<strong>${kendo.toString(data.date, 'd')}</strong>"))
            )
             

MajorTick(System.Int32)

The number of minutes represented by a major tick.

Parameters

majorTick - System.Int32

The majorTick

Example

Razor
 
            @(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)

Defines the template used to render the major ticks. By default, the Scheduler renders the time using the current culture time format. The available field in the template is "date", which represents the major tick date.

Parameters

majorTimeHeaderTemplate - System.String

The value that configures the template content.

Example

Razor
 
            @(Html.Kendo().Scheduler<Kendo.Mvc.Examples.Models.Scheduler.Screening>()
                .Name("scheduler")
                .MajorTimeHeaderTemplate("<strong>#=kendo.toString(date, 'h')#</strong><sup>00</sup>")
            )
             

MajorTimeHeaderTemplateId(System.String)

Defines the template used to render the major ticks. By default, the Scheduler renders the time using the current culture time format. The available field in the template is "date", which represents the major tick date.

Parameters

majorTimeHeaderTemplateId - System.String

The "id" attribute of the external Kendo UI Template.

Example

Razor
 
            @(Html.Kendo().Scheduler<Kendo.Mvc.Examples.Models.Scheduler.Screening>()
                .Name("scheduler")
                .MajorTimeHeaderTemplateId("TemplateID")
            )
            <script id="TemplateID" type="text/x-kendo-template">
                <strong>#=kendo.toString(date, 'h')#</strong><sup>00</sup>
            </script>
             

MajorTimeHeaderTemplateView(System.Web.Mvc.MvcHtmlString)

Defines the template used to render the major ticks. By default, the Scheduler renders the time using the current culture time format. The available field in the template is "date", which represents the major tick date.

Parameters

majorTimeHeaderTemplate - System.Web.Mvc.MvcHtmlString

The Razor View that contains the template.

Example

Razor
 
            @(Html.Kendo().Scheduler<Kendo.Mvc.Examples.Models.Scheduler.Screening>()
                .Name("scheduler")
                .MajorTimeHeaderTemplateView(Html.Partial("TemplateView"))
            )
             

MajorTimeHeaderTemplateHandler(System.String)

Defines the template used to render the major ticks. By default, the Scheduler renders the time using the current culture time format. The available field in the template is "date", which represents the major tick date.

Parameters

majorTimeHeaderTemplate - System.String

The JavaScript function that returns the template.

Example

Razor
 
            @(Html.Kendo().Scheduler<Activity>()
                .Name("scheduler")
                MajorTimeHeaderTemplateHandler("getMajorTimeHeaderTemplate"));
            )
            <script>
                function getMajorTimeHeaderTemplate(data) {
                    return `<strong>${kendo.toString(data.date, 'h')}</strong><sup>00</sup>`;
                }
            </script>
             

MajorTimeHeaderTemplate(Kendo.Mvc.UI.Fluent.TemplateBuilder)

Defines the template used to render the major ticks. By default, the Scheduler renders the time using the current culture time format. The available field in the template is "date", which represents the major tick date.

Parameters

template - TemplateBuilder<T>

A Template component that configures the template.

Example

Razor
 
            @(Html.Kendo().Scheduler<Activity>()
                .Name("scheduler")
                MajorTimeHeaderTemplate(Html.Kendo().Template().AddHtml("<strong>${kendo.toString(data.date, 'h')}</strong><sup>00</sup>")));
            )
             

MinorTickCount(System.Int32)

The number of time slots to display per major tick.

Parameters

minorTickCount - System.Int32

The minorTickCount

Example

Razor
 
            @(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)

Defines the template used to render the minor ticks. The available field in the template is "date", which represents the major tick date.

Parameters

minorTimeHeaderTemplate - System.String

The value that configures the template content.

Example

Razor
 
            @(Html.Kendo().Scheduler<Kendo.Mvc.Examples.Models.Scheduler.Screening>()
                .Name("scheduler")
                .MinorTimeHeaderTemplate("<strong>#=kendo.toString(date, 't')#</strong>")
            )
             

MinorTimeHeaderTemplateId(System.String)

Defines the template used to render the minor ticks. The available field in the template is "date", which represents the major tick date.

Parameters

minorTimeHeaderTemplateId - System.String

The "id" attribute of the external Kendo UI Template.

Example

Razor
 
            @(Html.Kendo().Scheduler<Kendo.Mvc.Examples.Models.Scheduler.Screening>()
                .Name("scheduler")
                .MinorTimeHeaderTemplateId("TemplateID")
            )
            <script id="TemplateID" type="text/x-kendo-template">
                <strong>#=kendo.toString(date, 't')#</strong>
            </script>
             

MinorTimeHeaderTemplateView(System.Web.Mvc.MvcHtmlString)

Defines the template used to render the minor ticks. The available field in the template is "date", which represents the major tick date.

Parameters

minorTimeHeaderTemplate - System.Web.Mvc.MvcHtmlString

The Razor View that contains the template.

Example

Razor
 
            @(Html.Kendo().Scheduler<Kendo.Mvc.Examples.Models.Scheduler.Screening>()
                .Name("scheduler")
                .MinorTimeHeaderTemplateView(Html.Partial("TemplateView"))
            )
             

MinorTimeHeaderTemplateHandler(System.String)

Defines the template used to render the minor ticks. The available field in the template is "date", which represents the major tick date.

Parameters

value - System.String

The JavaScript function that returns the template.

Example

Razor
 
            @(Html.Kendo().Scheduler<Activity>()
                .Name("scheduler")
                .MinorTimeHeaderTemplateHandler("getMinorTimeHeaderTemplate"))
            )
            <script>
                function getMinorTimeHeaderTemplate(data) {
                    return `<strong>${kendo.toString(data.date, 't')}</strong>`;
                }
            </script>
             

MinorTimeHeaderTemplate(Kendo.Mvc.UI.Fluent.TemplateBuilder)

Defines the template used to render the minor ticks. The available field in the template is "date", which represents the major tick date.

Parameters

template - TemplateBuilder<T>

A Template component that configures the template.

Example

Razor
 
            @(Html.Kendo().Scheduler<Activity>()
                .Name("scheduler")
                .MinorTimeHeaderTemplate(Html.Kendo().Template().AddHtml("<strong>${kendo.toString(data.date, 't')}</strong>")))
            )
             

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

Razor
 
            @(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

Razor
 
            @(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

Razor
 
            @(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

Razor
 
            @(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

Razor
 
            @(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

Razor
 
            @(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

Razor
 
            @(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

Razor
 
            @(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

Razor
 
            @(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

Razor
 
            @(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

Razor
 
            @(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

Razor
 
            @(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

Razor
 
            @(Html.Kendo().Scheduler<Task>()
               .Name("Scheduler")
               .Timezone("Etc/UTC")
               .Group(group => group.Resources("Rooms"))
               .Resources(resource =>
               {
                    resource.Add(m => m.RoomID)
                        .Title("Room")
                        .Name("Rooms")
                        .DataTextField("Text")
                        .DataValueField("Value")
                        .DataColorField("Color")
                        .BindTo(new[] {
                            new { Text = "Meeting Room 101", Value = 1, Color = "#6eb3fa" },
                            new { Text = "Meeting Room 201", Value = 2, Color = "#f58a8a" }
                        });
                    resource.Add(m => m.Attendees)
                        .Title("Attendees")
                        .Multiple(true)
                        .DataTextField("Text")
                        .DataValueField("Value")
                        .DataColorField("Color")
                        .BindTo(new[] {
                            new { Text = "Alex", Value = 1, Color = "#f8a398" } ,
                            new { Text = "Bob", Value = 2, Color = "#51a0ed" } ,
                            new { Text = "Charlie", Value = 3, Color = "#56ca85" }
                        });
                })
               .DataSource(d => d
                       .Model(m =>
                       {
                       m.Id(f => f.MeetingID);
                       m.Field(f => f.Title).DefaultValue("No title");
                       m.RecurrenceId(f => f.RecurrenceID);
                   })
                       .Read("Grouping_Horizontal_Read", "Scheduler")
               )
            )
             

Resources(System.Action)

Sets the resources configuration of the scheduler.

Parameters

addResourceAction - System.Action<SchedulerResourceFactory>

The lambda which configures the scheduler resources

Example

Razor
 
            @(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

Razor
 
            @(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

Razor
 
            @(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

Razor
 
             @( 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

Razor
 
            @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

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

DataSource(System.String)

Configures the DataSource options.

Parameters

dataSourceId - System.String

The DataSource name.

Example

Razor
 
              @( Html.Kendo().Scheduler<Task>()
                         .Name("Scheduler")
                         .DataSource("dataSource")
             )
              

CurrentTimeMarker(System.Action)

Sets the currentTimeMarker configuration of the scheduler.

Parameters

configurator - System.Action<SchedulerCurrentTimeMarkerSettingsBuilder>

The lambda which configures the currentTimeMarker

Example

Razor
 
            @(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

Razor
 
            @(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

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

OngoingEvents(System.Action)

The settings for the ongoing events highlight. The highlight is disabled by default. If you need to turn it on, set this option to true, or use a configuration object with its nested options.

Parameters

configurator - System.Action<SchedulerOngoingEventsSettingsBuilder>

The configurator for the ongoingevents setting.

OngoingEvents(System.Boolean)

The settings for the ongoing events highlight. The highlight is disabled by default. If you need to turn it on, set this option to true, or use a configuration object with its nested options.

Parameters

enabled - System.Boolean

Toolbar(System.Action)

Adds PDF command to the toolbar.

Parameters

addToolbarAction - System.Action<SchedulerToolbarFactory>

Example

Razor
 
            @(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

Razor
 
            @(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

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>

AsModule(System.Boolean)

Specifies whether the initialization script of the component will be rendered as a JavaScript module.

Parameters

value - System.Boolean

Render()

Renders the component.

Example

Razor
 
            @(@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();
            )
             

ScriptAttributes(System.Object,System.Boolean)

Sets the JavaScript attributes to the initialization script.

Parameters

attributes - System.Object

The JavaScript attributes.

overrideAttributes - System.Boolean

Argument which determines whether attributes should be overriden.

ScriptAttributes(System.Collections.Generic.IDictionary,System.Boolean)

Sets the JavaScript attributes to the initialization script.

Parameters

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

The JavaScript attributes.

overrideAttributes - System.Boolean

Argument which determines whether attributes should be overriden.

ToHtmlString()

ToClientTemplate()

In this article
MethodsDate(System.DateTime)Mobile()Mobile(Kendo.Mvc.UI.MobileMode)StartTime(System.DateTime)StartTime(System.Int32,System.Int32,System.Int32)EndTime(System.DateTime)EndTime(System.Int32,System.Int32,System.Int32)WorkDayStart(System.DateTime)WorkDayStart(System.Int32,System.Int32,System.Int32)WorkDays(System.Int32[])WorkDayEnd(System.DateTime)WorkDayEnd(System.Int32,System.Int32,System.Int32)Height(System.Int32)EventTemplate(System.String)EventTemplateId(System.String)EventTemplateView(System.Web.Mvc.MvcHtmlString)EventTemplateHandler(System.String)EventTemplate(Kendo.Mvc.UI.Fluent.TemplateBuilder)AllDayEventTemplate(System.String)AllDayEventTemplateId(System.String)AllDayEventTemplateView(System.Web.Mvc.MvcHtmlString)AllDayEventTemplateHandler(System.String)AllDayEventTemplate(Kendo.Mvc.UI.Fluent.TemplateBuilder)GroupHeaderTemplate(System.String)GroupHeaderTemplateId(System.String)GroupHeaderTemplateView(System.Web.Mvc.MvcHtmlString)GroupHeaderTemplateHandler(System.String)GroupHeaderTemplate(Kendo.Mvc.UI.Fluent.TemplateBuilder)AllDaySlot(System.Boolean)ShowWorkHours(System.Boolean)ShowWorkHours()Selectable(System.Boolean)DateHeaderTemplate(System.String)DateHeaderTemplateId(System.String)DateHeaderTemplateView(System.Web.Mvc.MvcHtmlString)DateHeaderTemplateHandler(System.String)DateHeaderTemplate(Kendo.Mvc.UI.Fluent.TemplateBuilder)MajorTick(System.Int32)MajorTimeHeaderTemplate(System.String)MajorTimeHeaderTemplateId(System.String)MajorTimeHeaderTemplateView(System.Web.Mvc.MvcHtmlString)MajorTimeHeaderTemplateHandler(System.String)MajorTimeHeaderTemplate(Kendo.Mvc.UI.Fluent.TemplateBuilder)MinorTickCount(System.Int32)MinorTimeHeaderTemplate(System.String)MinorTimeHeaderTemplateId(System.String)MinorTimeHeaderTemplateView(System.Web.Mvc.MvcHtmlString)MinorTimeHeaderTemplateHandler(System.String)MinorTimeHeaderTemplate(Kendo.Mvc.UI.Fluent.TemplateBuilder)Timezone(System.String)Width(System.Int32)Snap(System.Boolean)AutoBind(System.Boolean)WorkWeekStart(System.Int32)WorkWeekEnd(System.Int32)Editable(System.Action)Editable(System.Boolean)Footer(System.Action)Footer(System.Boolean)Min(System.DateTime)Max(System.DateTime)Group(System.Action)Resources(System.Action)Views(System.Action)Messages(System.Action)Events(System.Action)BindTo(System.Collections.Generic.IEnumerable)DataSource(System.Action)DataSource(System.String)CurrentTimeMarker(System.Action)CurrentTimeMarker(System.Boolean)Pdf(System.Action)OngoingEvents(System.Action)OngoingEvents(System.Boolean)Toolbar(System.Action)ToComponent()Name(System.String)Deferred(System.Boolean)ModelMetadata(System.Web.Mvc.ModelMetadata)HtmlAttributes(System.Object)HtmlAttributes(System.Collections.Generic.IDictionary)AsModule(System.Boolean)Render()ScriptAttributes(System.Object,System.Boolean)ScriptAttributes(System.Collections.Generic.IDictionary,System.Boolean)ToHtmlString()ToClientTemplate()
Not finding the help you need?
Contact Support