Topics
All
MacOS
(Only)
Windows
(Only)
Linux
(Only, Not)
iOS
(Only, Not)
Components
Crossplatform Mac & Win
Server
Client
Old
Deprecated
Guides
Examples
Videos
New in version:
12.1
12.2
12.3
12.4
12.5
13.0
13.1
13.2
13.3
13.4
Statistic
FMM
Blog
Returns the first source matching the type.
Component | Version | macOS | Windows | Linux | Server | iOS SDK |
Events | 6.2 | ✅ Yes | ❌ No | ❌ No | ❌ No | ✅ Yes |
Parameter | Description | Example | Flags |
---|---|---|---|
Type | The type of source. Can be Birthdays, Local, MobileMe, Exchange, CalDAV or Subscribed. |
"Local" | |
AsJSON | Available in MBS FileMaker Plugin 13.4 or newer. Pass 1 to return result as JSON. |
Optional |
Returns source identifier, empty or error.
Query local source:
MBS( "Events.SourceWithType"; "Local" )
Find a source for a new calendar:
# We need a source to add the new calendar to. I prefer local, but newer macOS doesn't have it, so we use caldav for iCloud
Set Variable [ $source ; Value: MBS( "Events.SourceWithType"; "local" ) ]
If [ IsEmpty ( $source ) ]
Set Variable [ $source ; Value: MBS( "Events.SourceWithType"; "caldav" ) ]
End If
Query as JSON:
MBS( "Events.SourceWithType"; "CalDAV"; 1 )
Example result:
{
"sourceTypeText" : "CalDAV",
"title" : "Mac.com",
"sourceIdentifier" : "68B72E23-6DC9-47EC-9C29-D844DB9F77BD",
"isDelegate" : false,
"sourceType" : 2
}
This function is free to use.
Created 24th March 2016, last changed 20th July 2023