How to access drop down in application using applescript?

百般思念 提交于 2019-12-03 10:20:54

问题


I'm trying to tell applescript to open the app, Application Loader, and choose from the drop down list that's in the window. The item that should be chosen will always be the very first item. How do i do this? Thanks in advance.


回答1:


Wow I finally got it working! I pretty much got mad at my script so I just put a random ASCII number and it magically worked. I got pretty happy aha :)

activate application "Application Loader"
tell application "System Events"
    tell process "Application Loader"
        tell the first combo box of window 1
            delay 3
            keystroke (ASCII character 30)
            keystroke (ASCII character 12)
            keystroke return
        end tell
    end tell
end tell


来源:https://stackoverflow.com/questions/7034038/how-to-access-drop-down-in-application-using-applescript

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!