[GH-ISSUE #26] Timezone information needs to be synced #483

Closed
opened 2026-03-01 17:39:14 +03:00 by kerem · 2 comments
Owner

Originally created by @aluxnimm on GitHub (Mar 26, 2015).
Original GitHub issue: https://github.com/aluxnimm/outlookcaldavsynchronizer/issues/26

Originally assigned to: @nertsch on GitHub.

Sncying an event from outlook to google calendar leads to incorrect timezone

The mapping in Map1To2 needs to be adjusted:

  target.Start = new iCalDateTime (source.StartUTC);
  target.DTEnd = new iCalDateTime (source.EndUTC);

In Sogo it works but the raw source has no timezone info aswell:
BEGIN:VCALENDAR
PRODID:-//ddaysoftware.com//NONSGML DDay.iCal 1.0//EN
VERSION:2.0
BEGIN:VEVENT
DTEND:20150325T113000
DTSTAMP:20150326T083642Z
DTSTART:20150325T110000
PRIORITY:5
SEQUENCE:0
SUMMARY:bla
UID:ee2562b4-ec88-450d-bef7-685e7fd83b70
CLASS:PUBLIC
END:VEVENT
END:VCALENDAR

The correct event shoud look like:
BEGIN:VCALENDAR
PRODID:-//ddaysoftware.com//NONSGML DDay.iCal 1.0//EN
VERSION:2.0
BEGIN:VTIMEZONE
TZID:Europe/Vienna
X-LIC-LOCATION:Europe/Vienna
BEGIN:DAYLIGHT
TZOFFSETFROM:+0100
TZOFFSETTO:+0200
TZNAME:CEST
DTSTART:19700329T020000
RRULE:FREQ=YEARLY;BYMONTH=3;BYDAY=-1SU
END:DAYLIGHT
BEGIN:STANDARD
TZOFFSETFROM:+0200
TZOFFSETTO:+0100
TZNAME:CET
DTSTART:19701025T030000
RRULE:FREQ=YEARLY;BYMONTH=10;BYDAY=-1SU
END:STANDARD
END:VTIMEZONE
BEGIN:VEVENT
DTEND;TZID=Europe/Vienna:20150325T123000
DTSTAMP:20150326T083642Z
DTSTART;TZID=Europe/Vienna:20150325T120000
PRIORITY:5
SEQUENCE:0
SUMMARY:bla
UID:ee2562b4-ec88-450d-bef7-685e7fd83b70
CLASS:PUBLIC
LAST-MODIFIED:20150326T084419Z
TRANSP:OPAQUE
END:VEVENT
END:VCALENDAR

Original comment by: aluxnimm

Original Ticket: outlookcaldavsynchronizer/16

Originally created by @aluxnimm on GitHub (Mar 26, 2015). Original GitHub issue: https://github.com/aluxnimm/outlookcaldavsynchronizer/issues/26 Originally assigned to: @nertsch on GitHub. Sncying an event from outlook to google calendar leads to incorrect timezone The mapping in Map1To2 needs to be adjusted: ``` target.Start = new iCalDateTime (source.StartUTC); target.DTEnd = new iCalDateTime (source.EndUTC); ``` In Sogo it works but the raw source has no timezone info aswell: BEGIN:VCALENDAR PRODID:-//ddaysoftware.com//NONSGML DDay.iCal 1.0//EN VERSION:2.0 BEGIN:VEVENT DTEND:20150325T113000 DTSTAMP:20150326T083642Z DTSTART:20150325T110000 PRIORITY:5 SEQUENCE:0 SUMMARY:bla UID:ee2562b4-ec88-450d-bef7-685e7fd83b70 CLASS:PUBLIC END:VEVENT END:VCALENDAR The correct event shoud look like: BEGIN:VCALENDAR PRODID:-//ddaysoftware.com//NONSGML DDay.iCal 1.0//EN VERSION:2.0 BEGIN:VTIMEZONE TZID:Europe/Vienna X-LIC-LOCATION:Europe/Vienna BEGIN:DAYLIGHT TZOFFSETFROM:+0100 TZOFFSETTO:+0200 TZNAME:CEST DTSTART:19700329T020000 RRULE:FREQ=YEARLY;BYMONTH=3;BYDAY=-1SU END:DAYLIGHT BEGIN:STANDARD TZOFFSETFROM:+0200 TZOFFSETTO:+0100 TZNAME:CET DTSTART:19701025T030000 RRULE:FREQ=YEARLY;BYMONTH=10;BYDAY=-1SU END:STANDARD END:VTIMEZONE BEGIN:VEVENT DTEND;TZID=Europe/Vienna:20150325T123000 DTSTAMP:20150326T083642Z DTSTART;TZID=Europe/Vienna:20150325T120000 PRIORITY:5 SEQUENCE:0 SUMMARY:bla UID:ee2562b4-ec88-450d-bef7-685e7fd83b70 CLASS:PUBLIC LAST-MODIFIED:20150326T084419Z TRANSP:OPAQUE END:VEVENT END:VCALENDAR Original comment by: aluxnimm Original Ticket: [outlookcaldavsynchronizer/16](https://sourceforge.net/p/outlookcaldavsynchronizer/16)
kerem 2026-03-01 17:39:14 +03:00
Author
Owner

@aluxnimm commented on GitHub (Mar 26, 2015):

Code Snippet that works for me as a quick fix without syncing the actual timezone:

  iCalDateTime startDate = new iCalDateTime(source.StartUTC);
  iCalDateTime endDate = new iCalDateTime(source.EndUTC);

  startDate.IsUniversalTime = true;
  endDate.IsUniversalTime = true;

  target.Start = startDate;
  target.DTEnd = endDate;

Original comment by: aluxnimm

<!-- gh-comment-id:126312507 --> @aluxnimm commented on GitHub (Mar 26, 2015): Code Snippet that works for me as a quick fix without syncing the actual timezone: ``` iCalDateTime startDate = new iCalDateTime(source.StartUTC); iCalDateTime endDate = new iCalDateTime(source.EndUTC); startDate.IsUniversalTime = true; endDate.IsUniversalTime = true; target.Start = startDate; target.DTEnd = endDate; ``` Original comment by: aluxnimm
Author
Owner

@aluxnimm commented on GitHub (Mar 31, 2015):

  • status: open --> closed
  • assigned_to: Gerhard Zehetbauer

Original comment by: nertsch

<!-- gh-comment-id:126312509 --> @aluxnimm commented on GitHub (Mar 31, 2015): - **status**: open --> closed - **assigned_to**: Gerhard Zehetbauer Original comment by: nertsch
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
starred/outlookcaldavsynchronizer#483
No description provided.