• 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
NSAppleScript question
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

NSAppleScript question


  • Subject: NSAppleScript question
  • From: Matthew Weinstein <email@hidden>
  • Date: Thu, 24 Jul 2003 08:44:09 -0400

Ok, I'm doing something wrong.

The following works as expected:
NSMutableString *as = [[NSMutableString alloc] init];
NSAppleScript *aa;
NSDictionary *errorInfo=0;
[as setString: @"say \"Hello world\""];
aa = [[NSAppleScript alloc] initWithSource: as];
if(![aa executeAndReturnError: &errorInfo])
[aa release];

But the following never succeeds:

NSMutableString *as = [[NSMutableString alloc] init];
NSAppleScript *aa;
NSDictionary *errorInfo=0;
[as setString: @"say \"Hello world\" saving to \"test.aiff\""];
aa = [[NSAppleScript alloc] initWithSource: as];
if(![aa executeAndReturnError: &errorInfo])
[aa release];


What am I doing wrong here? Am I missing something?

1000 thanks, Matthew
_______________________________________________
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.

  • Follow-Ups:
    • Re: NSAppleScript question
      • From: Fritz Anderson <email@hidden>
    • Re: NSAppleScript question
      • From: cricket <email@hidden>
  • Prev by Date: Re: Design for Cocoa (was Re: Can a subclass of NSDictionary do this?)
  • Next by Date: Re: time-based beta termination system
  • Previous by thread: Re: "current" selector as string
  • Next by thread: Re: NSAppleScript question
  • Index(es):
    • Date
    • Thread