See 4d-utility-sign-app on how to enable the plugin in 4D.
Alternatively use 4d-class-build-application to modify 4D entitlements.
Updated version of iCal API
You must first call iCal_Request_permisson
to ask permission from the user to access their calendar. It is an asynchronous call, which means that in the first instance, it will always return {"success":false}
. Later, after the user has granted permission, you might get {"success":true}
.
- If the main app (4D) does not have the required
Info.plist
property, the following error might be returned.
{
"success":false,
"errorMessage":"NScalendarUsageDescription is missing in app info.plist"
}
- If the main app (4D) does not have the required codesigning entitlements, the following error might be returned.
{
"success":false,
"errorMessage":"com.apple.security.personal-information.calendars is missing in app entitlement"
}
or
{
"success":false,
"errorMessage":"com.apple.security.personal-information.calendars is set to false in app entitlement"
}
If the main app (4D) has the required Info.plist
property as well as codesigning entitlement, and the user has not yet been asked for these permissions for the current application, up to 3 dialogs might be presented, one after the other.
Note: The plugin does not need access Reminder or Contacts. However the underlying API will prompt the requests.
The system will only display the dialogs once per application session, and never if the user has already denied the same request.
You can reset security settings from Terminal.
tccutil reset Reminders com.4d.4d
tccutil reset AddressBook com.4d.4d
tccutil reset Calendar com.4d.4d
After the dialog has been presented, one of the following status will be returned.
{
"success":true
}
{
"success":false,
"errorMessage":"permission denied"
}
{
"success":false,
"errorMessage":"permission restricted"
}
{
"success":false,
"errorMessage":"permission not determined"
}