Kendo.Mvc.UI.Fluent.DatePickerBuilder

Defines the fluent API for configuring the Kendo UI DatePicker

Methods

Animation(System.Boolean)

Use to enable or disable animation of the popup element.

Parameters

enable System.Boolean

The boolean value.

Example (ASPX)

@(Html.Kendo().DatePicker()
    .Name("DatePicker")
    .Animation(false) //toggle effect
)

Animation(System.Action<Kendo.Mvc.UI.Fluent.PopupAnimationBuilder>)

Configures the animation effects of the widget.

Parameters

animationAction System.Action<Kendo.Mvc.UI.Fluent.PopupAnimationBuilder>

The action which configures the animation effects.

Example (ASPX)

@(Html.Kendo().DatePicker()
    .Name("DatePicker")
    .Animation(animation =>
    {
        animation.Open(open =>
        {
            open.SlideIn(SlideDirection.Down);
        })
    })
)

DisableDates(System.DayOfWeek[])

Specifies the disabled dates in the DatePicker widget.

Example (ASPX)

@(Html.Kendo().DatePicker()
    .Name("datePicker")
    .DisableDates(DayofWeek.Saturday, DayOfWeek.Sunday)
)

DisableDates(System.String)

Specifies the disabled dates in the DatePicker widget using a function.

Example (ASPX)

@( Html.Kendo().DatePicker()
    .Name("datePicker")
    .DisableDates("disableDates")
)

Enable(System.Boolean)

Enables or disables the picker.

Value(System.String)

Sets the value of the picker input

Value(System.Nullable<System.DateTime>)

Sets the value of the picker input

FooterId(System.String)

FooterId to be used for rendering the footer of the Calendar.

Example (ASPX)

<%= Html.Kendo().DatePicker()
    .Name("DatePicker")
    .FooterId("widgetFooterId")
%>

Footer(System.Boolean)

Enables/disables footer of the calendar popup.

Example (ASPX)

<%= Html.Kendo().DatePicker()
    .Name("DatePicker")
    .Footer(false)
%>

MonthTemplateId(System.String)

MonthTemplateId to be used for rendering the cells of the Calendar.

Example (ASPX)

<%= Html.Kendo().DatePicker()
    .Name("DatePicker")
    .MonthTemplateId("widgetMonthTemplateId")
%>

MonthTemplate(System.String)

Templates for the cells rendered in the "month" view.

Example (ASPX)

<%= Html.Kendo().DatePicker()
    .Name("DatePicker")
    .MonthTemplate("#= data.value #")
%>

Min(System.String)

Sets the minimal date, which can be selected in DatePicker.

Max(System.String)

Sets the maximal date, which can be selected in DatePicker.

ARIATemplate(System.String)

Specifies a template used to populate value of the aria-label attribute.

Parameters

value System.String

The value for ARIATemplate

ARIATemplateId(System.String)

Specifies a template used to populate value of the aria-label attribute.

Parameters

templateId System.String

The ID of the template element for ARIATemplate

Culture(System.String)

Specifies the culture info used by the widget.

Parameters

value System.String

The value for Culture

DateInput(System.Boolean)

Specifies if the DatePicker will use DateInput for editing value

Parameters

value System.Boolean

The value for DateInput

DateInput

Specifies if the DatePicker will use DateInput for editing value

Dates(System.DateTime[])

Specifies a list of dates, which will be passed to the month template.

Parameters

value System.DateTime[]

The value for Dates

Footer(System.String)

The template which renders the footer of the calendar. If false, the footer will not be rendered.

Parameters

value System.String

The value for Footer

Format(System.String)

Specifies the format, which is used to format the value of the DatePicker displayed in the input. The format also will be used to parse the input.For more information on date and time formats please refer to Date Formatting.

Parameters

value System.String

The value for Format

Max(System.DateTime)

Specifies the maximum date, which the calendar can show.

Parameters

value System.DateTime

The value for Max

Min(System.DateTime)

Specifies the minimum date that the calendar can show.

Parameters

value System.DateTime

The value for Min

WeekNumber(System.Boolean)

If set to true a week of the year will be shown on the left side of the calendar. It is possible to define a template in order to customize what will be displayed.

Parameters

value System.Boolean

The value for WeekNumber

WeekNumber

If set to true a week of the year will be shown on the left side of the calendar. It is possible to define a template in order to customize what will be displayed.

ParseFormats(System.String[])

Specifies a list of date formats used to parse the value set with value() method or by direct user input. If not set the value of the format will be used. Note that the format option is always used during parsing.

Parameters

value System.String[]

The value for ParseFormats

Value(System.DateTime)

Specifies the selected date.

Parameters

value System.DateTime

The value for Value

Start(Kendo.Mvc.UI.CalendarView)

Parameters

value Kendo.Mvc.UI.CalendarView

The value for Start

Depth(Kendo.Mvc.UI.CalendarView)

Specifies the navigation depth.

Parameters

value Kendo.Mvc.UI.CalendarView

The value for Depth

MonthTemplate(System.Action<Kendo.Mvc.UI.Fluent.DatePickerMonthTemplateSettingsBuilder>)

Parameters

configurator System.Action<Kendo.Mvc.UI.Fluent.DatePickerMonthTemplateSettingsBuilder>

The configurator for the monthtemplate setting.

Events(System.Action<Kendo.Mvc.UI.Fluent.DatePickerEventBuilder>)

Configures the client-side events.

Parameters

configurator System.Action<Kendo.Mvc.UI.Fluent.DatePickerEventBuilder>

The client events action.

Example (ASPX)

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