I'm trying to make an automation that adds people to a FaceTime call. I tried using Accessibility Inspector to find where the + button is in the UI.
I'm don't know much AppleScript, so I just copied all the UI element types and names/indexes from Accessibility Inspector into Script Editor, but it gave me the error "Expected end of line but found number." When I remove the section 1 and collection 1 parts it builds, but when I run it it says that it "can't get group 1 of scroll area 1 of window 1." I've tried replacing "section" and "collection" with "UI Element," but that still didn't work. Do "collections" and "sections" have a different name when using AppleScript, or am I doing something else wrong?
Here's my current code:
tell application "System Events"
tell process "FaceTime"
click button 1 of group 1 of section 1 of collection 1 of scroll area 1 of window 1
end tell
end tell