Sql Server 2008 Express Date Format

Hi,

I’m storing events on a sql server 2008 express database, when I save an event the date format on the database is swapped around. If I add an event for 5th March 2012 (05/03/2012) it stores it on the database as (03/05/2012) I figured this was due to the xml_date format in scheduler
“%m/%d/%Y %H:%i”. I changed this format to “%d/%m/%Y %H:%i” but still no joy. Obviously this is a problem for me as events aren’t showing in the correct dates and entries above the 12th also aren’t displaying at all as a result. There is also an issue with the times displaying an hour ahead of what’s on the database but that’s another issue. Any help on this one would be much appreciated as I’m evaluating this for a client.

Thanks.

Hello,
when you change xml date format in scheduler’s configuration, you should change it in the data action as well(SchedulerAjaxData has DateFormat property), and make sure that date will be parsed in the save action. Try next:
set date formats in config and date action, and pass appropriate cultureInfo to the DHXEventsHelper.Bind method, in the save action

public ContentResult Save(int? id, FormCollection actionValues) { ... var changedEvent = (Event)DHXEventsHelper.Bind(typeof(Event), actionValues, System.Globalization.CultureInfo.CurrentCulture); ...