iCal (basic read and write).
Changes due to switching from CalendarStore to EventKit SDK:
- removed
calendar.notes
calendar.type
“IMAP” (CalCalendarTypeIMAP
)calendar.isEditable
event.dateStamp
recurrenceRule.recurrenceEnd.usesEndDate
-
added
calendar.immutable
calendar.allowsContentModifications
calendar.subscribed
event.lastModifiedDate
event.creationDate
recurrenceRule.weeksOfTheYear
recurrenceRule.daysOfTheYear
recurrenceRule.setPositions
status:=iCal_Request_permisson
For this command to work, the main app (4D) must be signin your app with the com.apple.security.personal-information.calendars
entitlement and have the NSCalendarsUsageDescription
property list key.
status:=iCal QUERY EVENT (options)
Parameters for options
startDate
: TEXT or DATEendDate
: TEXT or DATEcalendars
: COLLECTION of calendar objects. each object must have auid
ortitle
property
If status.success
, a collection of events will be returned in status.events[]
.
status:=iCal GET CALENDAR LIST
If status.success
, a collection of objects will be returned in status.calendars[]
.
status:=iCal Get default calendar
Retutns the default calendar and the list of available sources
. You can use one of them to create a new calendar.
status:=iCal Create calendar(options)
options
: Sepcify a calendar title
. By default, a “Local” type is created. You can optinally pass a source title, type or identifier in source
. A source identifier or type must match exactly. ?
and *
are allowed as wildcard characters for title.
status:=iCal Set calendar property(options)
options
: Spepcify a calendar by its uid
or title
. Only the title
and coler
are modifiable.
status:=iCal Get calendar property(options)
status:=iCal Remove calendar(options)
options
: Sepcify a calendar by its uid
or title
.
calendar properties
uid
: read only TEXTcolor
: LONGINT (see below)type
: read only TEXT (ee below )title
: TEXTsubscribed
: read only BOOLEANimmutable
: read only BOOLEANallowsContentModifications
: read only BOOLEANnotes
: TEXT Deprecated (3.2.0
)isEditable
: read only BOOLEAN Deprecated (3.2.0
)
Notes
uid
is mapped tocalendarIdentifier
color
seems to be “write only” for some calendars.type
can be Local, CalDAV, Exchange, Subscription, Birthday. “IMAP” is Deprecated (3.2.0
)
status:=iCal Set event property(options)
status:=iCal Get event property(options)
status:=iCal Create event(options)
status:=iCal Remove event(options)
event properties
uid
: read only TEXTstartDate
: TEXT or DATEendDate
: TEXT or DATEtitle
: TEXTlocation
: TEXTnotes
: TEXTurl
: TEXTcalendar
: OBJECTtimeZone
: read only OBJECTrecurrenceRule
: OBJECTisAllDay
: BOOLEANisDetached
: read only BOOLEANoccurrence
: read only TEXTcreationDate
: read only TEXTdateStamp
: read only TEXTalarms[]
: read only COLLECTION (see below)attendees[]
: read only COLLECTION (see below)
Notes
isAllDay
is mapped toallDay
url
is mapped toURL
occurrence
is mapped tooccurrenceDate
dateStamp
is mapped tolastModifiedDate
alarms
is currently read-only.
TODO: addAlarm:
, removeAlarm:
it is not possible to add attendees with Event Kit
alarm properties
action
: read only TEXTemailAddress
: read only TEXTsound
: read only TEXTurl
: read only TEXT Deprecated (3.2.0
)relativeTrigger
: read only REALabsoluteTrigger
: read only DATE
Notes
sound
is mapped tosoundName
relativeTrigger
is mapped torelativeOffset
absoluteTrigger
is mapped toabsoluteDate
action
is mapped totype
. It can be Sound, Display, Email, Procedure.
attendee properties
isCurrentUser
: read only BOOLrole
: read only TEXTtype
: read only TEXTstatus
: read only TEXTcommonName
: read only TEXTaddress
: read only TEXT
Notes
isCurrentUser
is mapped tocurrentUser
role
is mapped toparticipantRole
type
is mapped toparticipantRole
status
is mapped toparticipantStatus
commonName
is mapped toname
address
is mapped toURL
recurrenceRule properties
recurrenceInterval
: LONGINTfirstDayOfTheWeek
: LONGINTrecurrenceType
: LONGINTrecurrenceEnd
: OBJECTrecurrenceEnd.usesEndDate
: read only BOOLEAN Deprecated (3.2.0
)recurrenceEnd.endDate
: DATErecurrenceEnd.occurrenceCount
: LONGINTdayOfTheWeek
: LONGINT Deprecated (3.2.0
)weekOfTheMonth
: LONGINT Deprecated (3.2.0
)daysOfTheWeek[]
: COLLECTION of numbersdaysOfTheMonth[]
: COLLECTION of numbersnthWeekDaysOfTheMonth[]
: read only COLLECTION of objects Deprecated (3.2.0
)monthsOfTheYear[]
: COLLECTION of numbersweeksOfTheYear[]
: COLLECTION of numbersdaysOfTheYear[]
: COLLECTION of numberssetPositions[]
: COLLECTION of numbers
status properties
success
: BOOLEANerror
: OBJECT (ifsuccess
isfalse
)error.code
: LONGINTerror.localizedDescription
: TEXTerror.localizedRecoverySuggestion
: TEXT