Does Outlook correctly handle time zones for .ics (ICalendar) files?

Andrew Hagner picture Andrew Hagner · Jun 15, 2012 · Viewed 9.8k times · Source

I have a program that sends calendar appointments out to users. However these users are in many different time zones. When I create the .ics file, I set the time zone to the local time zone, because they are scheduled here. They then get sent out to the users, who are scattered across many time zones.

Will outlook handle this correctly? As in: if I schedule a person for an 8am meeting and I am in Philadelphia, it should come up as 8am meeting for them in any other time zone.

I know that Outlook works with time zones to an extent, but I couldn't find any good documentation on it.

EDIT: I really should have asked something more along the lines of how do you format it to handle this correctly, here is the format I am currently using. But I have little experience with this so I might be doing it wrong:

String[] iCalArr = {   "BEGIN:VCALENDAR",
                            "PRODID:-//foobar//morefoobar//EN",
                            "VERSION:2.0",
                            "CALSCALE:GREGORIAN",
                            "METHOD:REQUEST",
                            "BEGIN:VTIMEZONE",
                                "TZID:America/New_York",
                                "X-LIC-LOCATION:America/New_York",
                                "BEGIN:DAYLIGHT",
                                    "TZOFFSETFROM:-0500",
                                    "TZOFFSETTO:-0400",
                                    "TZNAME:EDT",
                                    "DTSTART:19700308T020000",
                                    "RRULE:FREQ=YEARLY;BYMONTH=3;BYDAY=2SU",
                                "END:DAYLIGHT",
                                "BEGIN:STANDARD",
                                    "TZOFFSETFROM:-0400",
                                    "TZOFFSETTO:-0500",
                                    "TZNAME:EST",
                                    "DTSTART:19701101T020000",
                                    "RRULE:FREQ=YEARLY;BYMONTH=11;BYDAY=1SU",
                                "END:STANDARD",
                            "END:VTIMEZONE",
                            "BEGIN:VEVENT",
                                "DTSTART;TZID=America/New_York:" + strBeginDate, 
                                "DTEND;TZID=America/New_York:" + strEndDate, 
                                "DTSTAMP:" + strNow,
                                "UID:DT 2012 Training - " + System.Guid.NewGuid().ToString(),
                                "RECURRENCE-ID;TZID=America/New_York:20110207T103000",
                                "CREATED:" + strNow,
                                "DESCRIPTION;ENCODING=QUOTED-PRINTABLE:foobar",
                                "LAST-MODIFIED:" + strNow,
                                "LOCATION:" + location, 
                                "SEQUENCE:1",
                                "STATUS:TENTATIVE",
                                  "SUMMARY:foobar",
                                "TRANSP:OPAQUE",
                              "END:VEVENT", "END:VCALENDAR" };

Answer

Paul-Jan picture Paul-Jan · Jun 15, 2012

Outlook should handle that just fine, assuming your particular application writes out proper timezone information. Or perhpaps works in UTC and marks everything with the Z zone.

I'm confused by your remark that "testing is not an option". I can imagine the unidentified "program" being unable to write out test data, but your question indicates you worry about Outlook. Surely you can handedit some ICS files with different timezones and feed them to Outlook? This should clearly indicate that Outlook knows how to deal with them.