This is a migrated thread and some comments may be shown as answers.

Kendo grid with date picker in rows update max valid

1 Answer 342 Views
Grid
This is a migrated thread and some comments may be shown as answers.
Noël Thoelen
Top achievements
Rank 1
Noël Thoelen asked on 06 Mar 2017, 09:57 AM

Hello,

I am having a kendo grid which is editable and the rows I am using the "DateTimeInGridEditor" template which has some settings as min and max values. This works as expected, however I want to change min max values as the values from the dates are changing, meaning that I want to have a timespan between them of x years or months.  I looked through the documentation and I do not find a way of doing this. From what I have experienced will mean that I will have to change the editor and make it all the way using javascript but I do not know how I can do this. Is there a sample available?

Thanks in advance.

1 Answer, 1 is accepted

Sort by
0
Konstantin Dikov
Telerik team
answered on 08 Mar 2017, 06:40 AM
Hi Noël,

For changing properties of the DatePicker editor dynamically (assuming this will be based on some other value of the data item) you could handle the Edit event of the Grid and get reference to the editor. Once you get reference to the API of the DatePicker you can use its max and min methods for changing the range:
Note that within the Edit event you have access to the model and its values.


Best Regards,
Konstantin Dikov
Telerik by Progress
Try our brand new, jQuery-free Angular 2 components built from ground-up which deliver the business app essential building blocks - a grid component, data visualization (charts) and form elements.
Tags
Grid
Asked by
Noël Thoelen
Top achievements
Rank 1
Answers by
Konstantin Dikov
Telerik team
Share this question
or