Re: Decide which mail app to use for mailto: links
Re: Decide which mail app to use for mailto: links
- Subject: Re: Decide which mail app to use for mailto: links
- From: Alex Zavatone <email@hidden>
- Date: Wed, 18 May 2016 18:10:35 -0400
What if you preceded that mailto url with another url scheme that could be mapped to your app?
Sent from my iPhone
> On May 18, 2016, at 1:04 PM, Paul Brown <email@hidden> wrote:
>
> I wrote a Mac app that is a little directory lookup tool. You search for a name (or partial name), it pulls user info from a database and shows the results in a table view. One of the columns is for Email Address. It is a button that shows the address on hover, and when clicked, it opens the mailto: link to compose an email to the person, like so:
>
> NSWorkspace.sharedWorkspace().openURL(NSURL(string:String(format:"mailto:%@",sender.alternateTitle))!)
>
> Is it possible to have the user select their preferred mail application that will respond to this? In my experience on iOS, there are URL schemes for many apps that let a variety of apps pass data to other apps. Is this a thing on OS X? The use case here is that I have my personal email account configured in Mail.app, and my work email configured in Outlook 2016. It would be great to have a pref pane in my app to let the user choose which mail app is used.
>
> PS - yes, I should probably not force-unwrap that NSURL. i’m getting there… :-)
>
> Thanks,
> Paul
> _______________________________________________
>
> Cocoa-dev mailing list (email@hidden)
>
> Please do not post admin requests or moderator comments to the list.
> Contact the moderators at cocoa-dev-admins(at)lists.apple.com
>
> Help/Unsubscribe/Update your Subscription:
>
> This email sent to email@hidden
_______________________________________________
Cocoa-dev mailing list (email@hidden)
Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden