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

Saving NULL datetime values with DateTimePicker

1 Answer 158 Views
Grid
This is a migrated thread and some comments may be shown as answers.
Jeff Ehrenberg
Top achievements
Rank 2
Jeff Ehrenberg asked on 06 Apr 2010, 07:46 PM
I have 2 grid columns that are bound to 2 datetime fields.  The database allows NULL values because there are times that a user can fill out some information on the form but leave the datetime empty.  The problem is when I save the edited grid rows any blank datetime fields get saved back to the database as '1/1/1900 12:00 AM'.  I have tried setting the ConvertEmptyStringToNull=true but it doesn't affect the save.

1 Answer, 1 is accepted

Sort by
0
Radoslav
Telerik team
answered on 09 Apr 2010, 10:34 AM
Hi Jeff,

Could you please verify that you do not set the Default Value property of the date time column in your database. Also we tried to reproduce the issue locally but to no avail.
I am sending you a simple example which demonstrate the desired functionality. Please check it out and let me know what differs in your case. Also it will be helpful if you send us a simple running project, demonstrating the problem. You could open a formal support ticket from your Telerik account and attach a ZIP file there. In that way we can reproduce and pinpoint the problems you're facing on our side and provide a solution.

Sincerely yours,
Radoslav
the Telerik team

Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items.
Tags
Grid
Asked by
Jeff Ehrenberg
Top achievements
Rank 2
Answers by
Radoslav
Telerik team
Share this question
or