TimePicker TagHelper Overview

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

The TimePicker enables users to select time values from a predefined list or enter new ones.

Telerik UI for ASP.NET Core Ninja image

The TimePicker 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 TimePicker

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

    <kendo-timepicker name="timepicker1"></kendo-timepicker>

Basic Configuration

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

                .Value("8:30 AM")
                .Min("8:00 AM")
                .Max("7:30 AM")

        <kendo-timepicker name="end" value="new DateTime(1900, 1, 1, 8, 30, 0)"
            min="new DateTime(1900, 1, 1, 8, 0, 0)" max="new DateTime(1900, 1, 1, 7, 30, 0)">

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-timepicker name="timepicker" parse-formats="ViewBag.ParseDates"></kendo-timepicker>

See Also

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