如何在Apple脚本中单击菜单栏菜单栏项菜单的菜单项?

时间:2015-10-21 09:01:47

标签: macos applescript

The menu bar:

The UI Brower:

Apple Script:

tell application "System Events"
    tell process "MacID"
        click menu item 9 of menu 1 of menu bar item 1 of menu bar 2
    end tell
end tell

1 个答案:

答案 0 :(得分:0)

我不知道如何使用没有命令短键的MacID和菜单项,但这里是如何使用击键执行:

tell application "System Events" keystroke "(key)" using command down