NSAppleScript

Helloo, I would liketo run an applescript thru my obj-c app. Is NSAppleScript the way to go? I would like to load an applescript (that would be located in the Resources folder of my app) and run it and then return a varible at the end of the script which is a list called errors.

Is this possible?

Thanks,
eli

Yes and yes.

http://developer.apple.com/documentation/Cocoa/Reference/Foundation/Classes/NSAppleScript_Class/Reference/Reference.html

http://www.cocoadev.com/index.pl?NSAppleScript

AppleScripts that return a string will return an NSAppleEventDescriptor object. Obtain the string value of the object with -[NSAppleEventDescriptor stringValue].