Re: os x gui scripting
Re: os x gui scripting
- Subject: Re: os x gui scripting
- From: Andrew Farmer <email@hidden>
- Date: Tue, 23 Dec 2008 01:16:21 -0800
On 22 Dec 08, at 02:58, Luca Cioria wrote:
If you say so.. but for example how would you click at specified
coordinates
in applescript? or get a pixel color?
Of course, if an app is scriptable I use appscpt or automator, but
in many
case, even websites, I have to follow this path.
If you're working with a web site, use Safari's "do JavaScript" verb.
But if you're working some other truly recalcitrant application, the
following sort of thing works:
tell application "Firefox" to activate
tell application "System Events"
tell process "Firefox"
click at {26, 12}
end tell
end tell
Note that the coordinates are absolute by default... this is NOT a
particularly robust solution.
_______________________________________________
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