• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: Adding files to iTune library in Cocoa app
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Adding files to iTune library in Cocoa app


  • Subject: Re: Adding files to iTune library in Cocoa app
  • From: has <email@hidden>
  • Date: Tue, 26 Jun 2007 18:40:27 +0100

Tom Harrington wrote:

// Compile (or load) AppleScript
NSAppleScript *scpt = [[NSAppleScript alloc] initWithSource:
@"on run {arg1, arg2}\n return arg1 & arg2 \n end"];


// Send event to AppleScript
NSDictionary *error;
NSAppleEventDescriptor *resDesc = [scpt executeAppleEvent:evtDesc
error:&error];

NSAppleScript's docs indicate that -executeAppleEvent:error: can't be used to send Apple events to other applications. In the present context-- sending events to iTunes-- it doesn't look as though the above approach would work. Is your framework somehow overriding this behavior?

My code sends an Apple event to an AppleScript, not an application, and what the AppleScript does then is its own business. I think what the documentation is trying to say is that -executeAppleEvent:error: can't be used as a sort of ersatz AESend.


HTH

has
--
http://appscript.sourceforge.net
http://rb-appscript.rubyforge.org
http://appscript.sourceforge.net/objc-appscript.html

_______________________________________________

Cocoa-dev mailing list (email@hidden)

Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com

Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden


  • Prev by Date: Re: Drawing from upper left
  • Next by Date: [moderator ] Re: ObjC 3D engine
  • Previous by thread: Re: Adding files to iTune library in Cocoa app
  • Next by thread: Test - ignore
  • Index(es):
    • Date
    • Thread