Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

With .ics files can I delete old events?

Im currently working on an .ics export from our application.

Can I somehow delete old events, so in my first import into outlook I have 152 events and during my second import I only have 100 events. Then I would like the import to automatically delete all 52 events from Outlook, is this possible?

I know that I can make events canceled, but that is not what I want.

like image 902
Fredrik Avatar asked Oct 14 '09 14:10

Fredrik


People also ask

How do I delete a calendar event in ICS?

Now, Suppose, because of any reason if appointment is cancelled, then User1 HAS to create an ics file and send it to User2, so that User2 can cancel his event from the local outlook.

Can I delete ICS files?

If you opened it as a calendar, the . iCS file should be listed in File > Account Settings > Internet Calendars. You can delete it from there.

How do I delete an ICS from my Iphone calendar?

ics) calendar by tapping a link to the calendar. Also: Start Calendar app, tap Calendars (bottom centre), tap ℹ and tap Delete at the bottom.


1 Answers

For me it worked by setting the X-WR-RELCALID tag in the header of the ics file. Then Outlook recognized the event as the same. Also set METHOD:CANCEL in the header and STATUS:CANCELLED in VEVENT. Like this:

This ics to create the event:

BEGIN:VCALENDAR
VERSION:2.0
PRODID:http://www.example.com/example/
X-WR-RELCALID:ABC
METHOD:PUBLISH
BEGIN:VEVENT
UID:ThisIsTheUID
SEQUENCE:0
ORGANIZER;CN="Mustermann, Max":MAILTO:[email protected]
SUMMARY:Eine Kurzinfo
DESCRIPTION:Beschreibung des Termines
CLASS:PUBLIC
TRANSP:TRANSPARENT
DTSTART:20110804
DTEND:20110805
DTSTAMP:20110804
END:VEVENT
END:VCALENDAR

This ics to cancel/remove the event:

BEGIN:VCALENDAR
VERSION:2.0
PRODID:http://www.example.com/example/
X-WR-RELCALID:ABC
METHOD:CANCEL
BEGIN:VEVENT
UID:ThisIsTheUID
SEQUENCE:2
ORGANIZER;CN="Mustermann, Max":MAILTO:[email protected]
SUMMARY:Eine Kurzinfo
DESCRIPTION:Beschreibung des Termines
CLASS:PUBLIC
TRANSP:TRANSPARENT
DTSTART:20110804
DTEND:20110805
DTSTAMP:20110804
STATUS:CANCELLED
END:VEVENT
END:VCALENDAR
like image 193
Marc Avatar answered Sep 21 '22 08:09

Marc