Incremental Steps

By default, the DateTimePicker input increments or decrements each part of its date values by one step.

To change the default setup, use the steps property. The incremental steps configuration also affects the popup steps of the TimePicker.

The available options are:

  • year: Number—Controls the incremental step of the year value.
  • month: Number—Controls the incremental step of the month value.
  • day: Number—Controls the incremental step of the day value.
  • hour: Number—Controls the incremental step of the hour value.
  • minute: Number—Controls the incremental step of the minute value.
  • second: Number—Controls the incremental step of the second value.
@Component({
    selector: 'my-app',
    template: `
        <div class="example-wrapper">
            <p>Select date and time:</p>
            <kendo-datetimepicker
                [steps]="steps"
                [format]="format"
                [value]="value"
            >
            </kendo-datetimepicker>
            <p>(↑ to increment and ↓ to decrement the value)</p>
        </div>
    `
})

class AppComponent {
    public steps: any = { year: 10, month: 2, day: 5, hour: 2, minute: 15, second: 30 };
    public format: string = 'MM/dd/yyyy HH:mm:ss';
    public value: Date = new Date(2005, 4, 25, 21, 45);
}

In this article