On Fri, 21 May 2010 18:05:00 +0530, Dan Ribe <dan.r...@gmail.com> said:
>Hi All,
>
>I am working on to make my cocoa application scriptable. I want to automate
>the testing of my application and for that I want all the actions which user
>can performs manually to be scriptable. Like apple script should be able to
>open a dialog, type something in the text box (or any other UI element),
>then save (or perform any action with that dialog as we do manually).

No. That is not what AppleScript is about. AppleScript is about providing a
scripting API to your functionality. You don't use AppleScript to open a
dialog or type something in a text box. You use AppleScript to accomplish
what that dialog accomplishes (e.g. save this file in this place with this
name).

What you are describing is GUI scripting. Your app (if Cocoa) already
responds to GUI scripting. You can use AppleScript to do GUI scripting, but
then it is not your app that is scriptable; it's System Events that is
scriptable, and the Accessibility API is being used to click your app's
buttons etc. m.

-- 
matt neuburg, phd = m...@tidbits.com, <http://www.tidbits.com/matt/>
A fool + a tool + an autorelease pool = cool!
AppleScript: the Definitive Guide - Second Edition!
http://www.tidbits.com/matt/default.html#applescriptthings



_______________________________________________

Cocoa-dev mailing list (Cocoa-dev@lists.apple.com)

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:
http://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com

This email sent to arch...@mail-archive.com

Reply via email to