Home Help Center

Ice and Applescript on OS/X (C++ vs Obj-C)?

lancepwlancepw Member Lance WelshOrganization: BooyahProject: iPhone
I'm writing an application to provide remote access to iTunes and other apple goodies (Apple provides this access via Applescript). I'd like to use Ice, but before I go that route, I need to know if there is some common ground/language between Ice and Applescript. Development on a mac (Xcode, cocoa, etc) is new turf for me - I'd appreciate any advice.

Is Ice available in Objective-C as well as C++?

Can applescript can be called from C++ (I see mostly Objective-C examples around develop.apple.com)?

If it is the unfortunate case that Ice is available only in C++ and Applescript is available only in Objective-C, are there any bridges that can be built (I suppose one could always encapsulate Applescript functions as shell-callable programs, but that seems very inefficient and also difficult for dealing with binary data; I've hear that Applescript has some support for XML-RPC and SOAP).

Thanks, -Lance.


  • benoitbenoit Rennes, FranceAdministrators, ZeroC Staff Benoit FoucherOrganization: ZeroC, Inc.Project: Ice ZeroC Staff
    Hi Lance,

    You can link C++ code with Object-C code (it's called Objective-C++, see here).

    So you should be able to write an Objective-C++ application that links with the Ice library and acts as an Ice server. It can call Objective-C code to execute some AppleScript code. To execute AppleScript code, I would probably use the NSAppleScript class from the fundation framework (see here and here).

    There's some sample code here showing how to use NSAppleScript to call iTunes.

    Hope this helps!

Sign In or Register to comment.