DatePicker TagHelper Overview

The Telerik UI DatePicker TagHelper for ASP.NET Core is a server-side wrapper for the Kendo UI DatePicker widget.

The DatePicker enables the user to enter or pick a date value.

Telerik UI for ASP.NET Core Ninja image

The DatePicker is part of Telerik UI for ASP.NET Core, a professional grade UI library with 110+ components for building modern and feature-rich applications. To try it out sign up for a free 30-day trial.

Initializing the DatePicker

The following example demonstrates how to define the DatePicker by using the DatePicker TagHelper.

  <kendo-datepicker name="datepicker1"></kendo-datepicker>

Basic Configuration

The DatePicker TagHelper configuration options are passed as attributes of the tag.

                .Format("MMMM yyyy")

        <kendo-datepicker name="monthpicker" start="CalendarView.Year" depth="CalendarView.Year"
            format="MMMM yyyy" value="DateTime.Now">

The ParseFormats option is of type string[] and can be assigned either by a ViewBag property or by a property of the model.

        ViewBag.ParseDates = new string[] { "MMMM yyyy", "MMMM" };

    <kendo-datepicker name="datepicker" parse-formats="ViewBag.ParseDates"></kendo-datepicker>

See Also

In this article
Not finding the help you need? Improve this article