We observe the following problem related to time differences between our MVC application and Kendo DatePicker. The web server runs in UTC + 0. Web clients work in different time zones (UTC + 1, UTC + 3, UTC-5, etc.).
On the web page there is a choice of date for the date (without the time part), where the user selects one day or month. Behind the scenes, the Date is sent on AJAX request using complete Date objects that contain time and time zone information.
We are only interested in the part of the date, no matter what time zone the client is in. When the user selects the date / month, we want to get C # DateTime in the local server.
For example:
User is at UTC + 1 and selects '01 / 07/2013 Actual C # DateTime object is created as '30 / 06/2013 23:00 We expect to get '01 / 07/2013 00:00:00
We are currently using the following setting in Global.asax:
GlobalConfiguration.Configuration.Formatters.JsonFormatter.SerializerSettings.DateTimeZoneHandliig = Newtonsoft.Json.DateTimeZoneHandling.Local;
Could you advise?
javascript timezone rest asp.net-mvc-3 kendo-ui
maulemon
source share