-->

URL Scheme for opening the iCal app at a date or e

2020-07-17 07:07发布

问题:

The Apple URL Scheme Reference gives a nice overview of a number of URL schemes you can use to open certain built-in apps with some parameters.

I know that this is not a complete list of all possible URL schemes that the built-in apps respond to, since there are also ways to open the system settings at various pages. The website http://handleopenurl.com is a nice attempt at gathering all possible URL schemes and it has quite a few built-in apps on there.

One app I would like to open with a URL scheme is the Calendar app (formerly known as iCal). But is there a scheme? If you know there is, please do share (optionally adding it to handleopenurl.com first?). Cheers!

P.S. Yes, I'm aware of the features of the EventKit(UI) frameworks. But I'd like to specifically open the iCal app.

回答1:

Probably the Answer is No. You need to look at this similar question and other similar question which is marked as accepted so hopefully is true.



回答2:

I can't find any documentation on the parameters, but typing ical:// into an open browser address bar opens Calendar.app on macOS Sierra 10.12.1.

Note: As far as Apple apps go, this also works with reminders://... maybe others



回答3:

You can try this code:

NSString* launchUrl = @"calshow://";
[[UIApplication sharedApplication] openURL:[NSURL URLWithString: launchUrl]];