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

Convert kendodatepicker format to .Net DateTime

2 Answers 128 Views
Date/Time Pickers
This is a migrated thread and some comments may be shown as answers.
Madzie
Top achievements
Rank 1
Madzie asked on 18 Nov 2013, 03:50 AM
The Json value of kendodatepicker that is received at .net csharp code is "\"2013-11-18T03:38:21.843Z\""What is the best and universal way to parse/convert this format to c# DateTime ?

2 Answers, 1 is accepted

Sort by
0
Madzie
Top achievements
Rank 1
answered on 20 Nov 2013, 01:36 AM
Any help on this ?
And also, in javascript when it is bound to one of the variables, the value is shown as Tue Nov 19 2013 17:27:51 GMT-0800 (Pacific Standard Time). 
I need to get just the date - 11/18/2013 or any other format... as it displays in the kendodatepicker textbox.
0
Georgi Krustev
Telerik team
answered on 20 Nov 2013, 08:21 AM
Hello Madzie,

In general, you define custom model binder and parse the incoming date in the way you want. Check this stackoverflow thread dedicated to the same subject.

Please note that this issue is related to ASP.NET MVC framework than Kendo UI.

Regards,
Georgi Krustev
Telerik
Join us on our journey to create the world's most complete HTML 5 UI Framework - download Kendo UI now!
Tags
Date/Time Pickers
Asked by
Madzie
Top achievements
Rank 1
Answers by
Madzie
Top achievements
Rank 1
Georgi Krustev
Telerik team
Share this question
or