开发者

Refresh .ICS file when updates occur

I have a database that puts out an .ics file that looks like this开发者_运维问答:

BEGIN:VCALENDAR
VERSION:2.0
PRODID:-//hacksw/handcal//NONSGML v1.0//EN
BEGIN:VEVENT
UID:36@homewoodphoto.jhu.edu
DTSTAMP:20091211T175956Z
DTSTART:20091106T200000Z
DTEND:20091106T230000Z
SUMMARY:
END:VEVENT
BEGIN:VEVENT
UID:35@homewoodphoto.jhu.edu
DTSTAMP:20091211T175956Z
DTSTART:20091105T220000Z
DTEND:20091106T010000Z
SUMMARY:
END:VEVENT
BEGIN:VEVENT
UID:34@homewoodphoto.jhu.edu
DTSTAMP:20091211T175956Z
DTSTART:20091106T200000Z
DTEND:20091106T230000Z
SUMMARY:
END:VEVENT
END:VCALENDAR

I'm able to subscribe to it easily through most email clients, even Microsoft Outlook 2007. However, after a client subscribes to the file, it's almost impossible to get it to refresh the file when updates occur.

Is there a way to force or push updates out to the clients from inside the .ics file? Or from inside Outlook, even if it's not on Exchange?


You have to reissue the ical, but you need to do 2 things:

  1. Keep the same UID.

  2. You need to add a SEQUENCE header (which is a simple integer). You then increment the sequence number for each new update.

Here is what an update would look like:

BEGIN:VEVENT
UID:34@homewoodphoto.jhu.edu
DTSTAMP:20091211T175956Z
DTSTART:20091106T200000Z
DTEND:20091106T230000Z
SUMMARY:
SEQUENCE:1
END:VEVENT


The only answer we've found to this question is: You can't do it. As of now, there's no way to control how often calendar clients will refresh and update based on your .ics file.

In other words, there's no "push" technology for calendar updates, the client program pulls whenever it feels like it. So if you are building a database with updated events that you want to push to people's calendars immediately, well... you can't. :(

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜