I’m using C#.NET to calculate the time stamp, and I’m assuming the time stamp is the total number of seconds of the occurrence since UNIX epoch.
Here is a rough snippet of my calculation code. Can you see what I’m doing wrong? (Aside from not dividing by 1000)
var startTime = new DateTime(2012, 9, 5, 8, 0, 0, 0, DateTimeKind.Utc);
var unixEpoc = new DateTime(1970, 1, 1, 0, 0, 0, 0, DateTimeKind.Utc);
var timestampOfWhenTheEventShouldHaveOccured = startTime.Subtract(unixEpoc);
var event_Length = timestampOfWhenTheEventShouldHaveOccured.TotalSeconds;
// event_Length comes out as 1346832000
this option will force usage of GMT timestamps in recurring events, so they will work correctly for any timezone ( default ones may not work if event-exception was created in one timezone and was checked in different timezone )
It has a 7 hours difference which is probably a time difference between our timezones.
If your calendar will be used in local timezone - it doesn’t matter at all. If you are creating global solution - check the above option.
Turns out, when I generated the event_length value:
I had to provided the UTC time stamp from Unix Epoc, ignoring the time zone offset.
I also had to take into account the one hour offset caused by Daylight Savings Time, if it applied.
Thanks again for your help.
Get a guaranteed answer from DHTMLX technical support team
under the most suitable support plan