tags:

views:

146

answers:

1

Hi

I am creating a CMI plugin in Carbon to add a menu item to my Finder's context menu. I would like call some web services when the item is clicked. Now since the context menu selection handler is written in C, I am not very sure if I would like to do it there.

Is it possible to call a Cocoa application on the context menu item's click? I know I can make a process the front process in the handle event. This would bring my cocoa application to the front. But how do I first run the application? Will using AECreateAppleEvent resolve my problem? If yes what params do I pass to it in order to launch a new application (I am not very familiar with Apple Event Manager)?

Thanks a lot for any help.

+1  A: 

Sounds like you want LSOpenApplication (along with LSFindApplicationForInfo to get the FSRef for the application you want to launch).

smorgan
Thanks a lot for the headsup.
lostInTransit