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

NumericTextBoxFor with nullable columns?

2 Answers 104 Views
NumericTextBox
This is a migrated thread and some comments may be shown as answers.
Reid
Top achievements
Rank 2
Reid asked on 15 Jan 2019, 06:16 PM
How is that handled?  Binding to a column that is a nullable date time?

2 Answers, 1 is accepted

Sort by
0
Accepted
Viktor Tachev
Telerik team
answered on 18 Jan 2019, 01:15 PM
Hello Reid,

If you would like to edit a DateTime field I would recommend using a DatePicker or DateTimePicker widget. They are designed to work with DateTime values out of the box. When the underlying field in the Model is null the pickers will not show any value.

In case you have a Grid and would like to edit a column bound to DateTime then the picker would be in a partial view located in ~/Views/Shared/EditorTemplates folder. Check out the article below that describes in more details on how Editor Templates can be defined in the Grid.



Regards,
Viktor Tachev
Progress Telerik
Get quickly onboarded and successful with your Telerik and/or Kendo UI products with the Virtual Classroom free technical training, available to all active customers. Learn More.
0
Reid
Top achievements
Rank 2
answered on 18 Jan 2019, 02:35 PM
Thank you Viktor.
Tags
NumericTextBox
Asked by
Reid
Top achievements
Rank 2
Answers by
Viktor Tachev
Telerik team
Reid
Top achievements
Rank 2
Share this question
or