I’m trying to automate an application that’s very non-standard using System Events, which seems to be recommended.
However, the only thing System Events can find is something called “menu bar 1”. For example:
activate application "Foo"
tell application "System Events"
tell process "Foo"
click at {500, 500}
end tell
end tell
prints
menu bar 1 of application process "Foo" of application "System Events"
I can ask what UI Elements are in the app:
activate application "Foo"
tell application "System Events"
tell process "Foo"
UI Elements
end tell
end tell
which prints
get every UI element of process "Foo"
--> {menu bar 1 of application process "Foo"}
The menu bar itself has no real actions available. How can I get access to the main content of the app so I can click on things?
2