0

I want to be reminded about something every week every winter. Is that possible to achieve using the ical-/webcal-standard and Google Calender, Apple Calendar/iCal, Android Calender or similar?

(I searched quite extensively for which subdomain this questioned belonged to but the results were inconclusive, with a slight predominance for SO)

d-b
  • 695
  • 3
  • 14
  • 43
  • Is your question about how to do that in the UI on one of these platforms or is it about how to write an iCalendar RRULE that will accomplish this? – Marten Jan 18 '16 at 15:10
  • It is about how to create such an event in any UI available – d-b Jan 18 '16 at 17:44

1 Answers1

2

It's definitely possible with RFC 5545 recurrence rules.

You can create a WEEKLY RRULE that recurs in specific months only, like so:

FREQ=WEEKLY;BYDAY=MO;BYMONTH=1,2,12

The occurrences of this rule are all Mondays in January, February and December.

Check out the first 100 instances of such an event at http://recurrence-expansion-service.appspot.com/reaas?dtstart=20160104&rrule=FREQ%3DWEEKLY%3BBYDAY%3DMO%3BBYMONTH%3D1%2C2%2C12&skip=&max_instances=100&expansion_window_end=21000104&rfc2445=1

Changing the rule to DAILY would yield the same results, but might be more compatible with actual implementations.

However, I think most calendar UIs don't provide this level of control over recurrence rules.

update:

To create an all day event starting on Dec 15 2015 and recur on the same day of week use:

DTSTART;VALUE=DATE:20151215
RRULE:FREQ=WEEKLY;BYMONTH=1,2,12

The rule doesn't include March itself. To include March just append ,3 to the rule.

Community
  • 1
  • 1
Marten
  • 3,802
  • 1
  • 17
  • 26
  • Thank you. Almost there. What remains are (I hope), 1. the event should be all day, 2. I want them to start Dec 15 and reappear every 7 days after that until March. How do I write such a rule? – d-b Jan 18 '16 at 17:48
  • can anyone tell me if there's a way to prevent creating events on the startdate if the startdate does not fall into the bydate rule? my code `{ 'summary': 'testing the calendar api', 'start': {'dateTime': '2020-06-04T23:00:00', 'timeZone': 'Asia/Dhaka'}, 'end': {'dateTime': '2020-06-04T23:30:00', 'timeZone': 'Asia/Dhaka'}, 'attendees': [{ 'email': 'ksrahman@iub.edu.bd' }], 'recurrence': ['RRULE:FREQ=WEEKLY;BYDAY=FR,SA;UNTIL=20200615'] }` – sakib11 Jun 04 '20 at 17:35
  • @sakib11 you should open another question for this. It's unrelated to the original question. – Marten Jun 10 '20 at 06:40