我正在尝试安装Adobe Flash Player,我想选中复选框并需要单击安装按钮,当我试图通过UIElementInspector获取window的全部内容时,我无法获取复选框和安装按钮的内容。
我刚试着用下面的脚本点击复选框,但没有成功,错误是unable to get the checkbox..请建议如何检查..
tell application "System Events"
tell process "Adobe Flash Player Install Manager"
set frontmost to true
click the checkbox "I have read and agree to the terms of the Flash Player License Agreement" of window "Adobe Flash Player 11.5 Installer."
end tell
end tell请点击下面的链接查看Adobe Flash Player安装程序的图片。
https://docs.google.com/document/d/1yzyBTrvi94QxjlEAlcbudOBpXiTGPEI2LA3D1iEo8Gw/编辑
发布于 2012-11-06 18:38:32
下载此软件:
http://pfiddlesoft.com/uibrowser/downloads/UIBrowser222.dmg
安装它。
您可以简单地使用此工具来读取复选框和所有复选框的名称。
例如:如果你附加了一个有窗口和复选框的应用程序,你可以通过下面的脚本选中这个复选框:
tell aplication "system events"
click checkbox 1 of window 1
end tell只需记住,在其他窗口中,将窗口保持在最前面。
您可以通过单击UI浏览器应用程序中存在的目标弹出按钮来附加流程。
然后单击Switch to screen reader选项。
现在可以看到按钮、控件、checkbo的名称
https://stackoverflow.com/questions/13229239
复制相似问题