Mac Messages App

Hi, sorry if someone else has already asked this - had a quick scan around and couldn’t find anything. Is there a way to get Xojo, either native or through a declare / plug-in to work with the Apple Messages app - i.e. in some apps, you have the sharing icon in the toolbar, clicking this will reveal a small window where you can compose a message for messages app to the send… see attachment - any points appreciated. Dave.

NSSharingServices, it’s accessible via both declares and plugins. If you have the MBS already, it’s in there, if not… Maybe someone has a some code ready to share. If I weren’t so busy, I’d create you an example project.

Yes, once again Christian and his plug-ins have made life so simple. What a breeze. Happy days :slight_smile:


I know… You already have answers :slight_smile:

Just in case someone wants to have a look at an example Xojo project that doesn’t require Plugins - here you are: macOS: NSSharingService (Email, Messages, AirDrop)

It’s been fun for me to learn how to use Declares to build the required Cocoa classes (e.g. to build the Delegate that conforms to a Protocol, and have that one send back to a Xojo method).

Anyway - here is a ScreenShot of the example project that uses NSSharingService to show a pre-composed Message (that’s being sent via

NSSharingServices is a ghost of it’s former self, it used to include various social media, but has now become an Apple only service. The sad thing is that 90% of our customers used it for social media, so once again we’re back to pre 2010s as each developer has to roll their own solution for social media.

The hardest thing we found when doing this before NSSharingServices was keeping up with the various Social Media and changes to their platforms, some would notify you, some would just change and break your application. When Apple added NSSharingServices, this was great because they managed this part for us.