Programmatically change email client / mailto: handler

Hi All,

I’d like to know if there’s a way to change the default mailto: URL handler in OS X. I know how to do this for http in Objective-C, but simply switching out http: with mailto: doesn’t seem to work. Thanks in advance.

p.s. I’m looking for a sandbox-compliant way of doing this

Obj-C code I have for changing http handler:

CFStringRef browserBundleID = (__bridge CFStringRef)@"";  

LSSetDefaultHandlerForURLScheme(CFSTR("http"), browserBundleID);
NSAppleEventManager *em = [NSAppleEventManager sharedAppleEventManager];


This suggests you may be out of luck:

Thanks for this link Shane! Looks like I’ll be submitting a bug report to Apple tonight :confused: