We are using kendo-vue-dateinputs DateTimePicker in our vuejs app.
When the control has a datetime, is there a way to clear the datetime to null?
Is there a way to add a button to the DateTimePicker where I can call my function to set the value to null?
1 Answer, 1 is accepted
0
Petar
Telerik team
answered on 14 Feb 2022, 09:39 AM
Hi Jerry,
The DateTimePicker value is controlled by the value property of the component. If you set the value of the property bound to the component to "null" the value of the DateTimePicker will be reset.
Here is a StackBlitz example demonstrating the described above. Currently, the DateTimePicker doesn't provide the option of defining a custom toggle button like it is possible in the DatePicker component. The functionality of defining a custom toggle button is in our tasks queue and will be available in a short time in the future. I cannot say exactly when this will happen. The previous aims to say that currently there is no way to add additional "clear" button in the DateTimePicker.
Please check the linked example and let me know if it demonstrates what you need to achieve in your application.
Regards,
Petar
Progress Telerik
Virtual Classroom, the free self-paced technical training that gets you up to speed with Telerik and Kendo UI products quickly just got a fresh new look + new and improved content including a brand new Blazor course! Check it out at https://learn.telerik.com/.