passing parameters to an AppleScript from Objective-C
passing parameters to an AppleScript from Objective-C
- Subject: passing parameters to an AppleScript from Objective-C
- From: Daniel Morrow <email@hidden>
- Date: Wed, 16 Feb 2005 12:17:40 -0500
Dear list,
I'm a recent convert from Carbon-land, and I'm still feeling my way
around Cocoa. So, please excuse my ignorance.
I have an app which includes an AppleScript file. I want to load and
execute the script, but also pass a parameter to it.
If I had no parameters, I think I'd do something like this:
NSDictionary* theDict = [NSDictionary new];
NSAppleScript* exportDataScript = [[NSAppleScript alloc]
initWithContentsOfURL:exportDataScriptURL error:&theDict];
NSAppleEventDescriptor* desc = [exportDataScript
executeAndReturnError:&theDict];
The parameter I'm passing is an AEDescList, if that makes any
difference.
Thanks for any help, or links to the docs which explain this,
-Dan.
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Cocoa-dev mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden