Re: communicating with other applications
Re: communicating with other applications
- Subject: Re: communicating with other applications
- From: David Remahl <email@hidden>
- Date: Sat, 22 Jun 2002 14:21:41 +0200
>
Look at NSTask.. that is more than likely what you want..
I disagree...
>
Cheers
>
>
-SJM>> Hello,
>
>
>
> I have a Cocoa app and would like to add functionality
>
> so the app can communicate with other applications on
>
> the same computer and the OS (opening other
>
> applications ...etc.). What is the best way to go
>
> about doing this?
AppleScript/AppleEvents. Definitely. If you just want to open an app, then
NSWorkspace or LaunchServices may be what you want. If you need to
communicate with an application you created yourself (or have in-depth
knowledge of) you should use Distributed Objects or Mach ports for maximum
efficiency (although AE will do just as well).
>
> 1) Invoke an AppleScript from the Cocoa app? If so,
>
> how is this implemented? Would I need to create an
>
> AppleScript Studio application rather than a Cocoa
>
> application (all of the code is currently writing on
>
> Objective C)?
You can use the class NDAppleScriptObject (please search the archives) or
NSAppleScript (which is part of Jaguar).
>
> 2) Send Apple Events from the Cocoa app?
Just use the Carbon calls.
/ David
_______________________________________________
cocoa-dev mailing list | email@hidden
Help/Unsubscribe/Archives:
http://www.lists.apple.com/mailman/listinfo/cocoa-dev
Do not post admin requests to the list. They will be ignored.