Client side date change UTC problem
Hi,
I'm trying to change the DayPilot dates from the client side:
JavaScript:
DayPilotCal.ChangeDates(dateFirst,DaysSelect);
C#:
protected void DayPilotCalendar1_Refresh(object sender, RefreshEventArgs e)
{
DayPilotCalendar1.StartDate = e.StartDate;
DayPilotCalendar1.Days = e.Days;
DayPilotCalendar1.Update(data, CallBackUpdateType.Full);
}
I keep getting different dates in the server side:
dateFirst = Sun Apr 19 12:00:00 UTC+0200 2009
e.StartDate = {19/04/2009 10:00:00}
dateFirst = Sun Apr 5 00:00:00 UTC+0200 2009
e.StartDate = {04/04/2009 22:00:00}
There is a 2 hours offset because of the UTC.
How should I handle changing the DayPilot Dates from the JS?
Thanks.
Rafael
Asked by Rafael 2 years ago.