WebDriver单击"Java窗口" [英] WebDriver click on "Java window"
问题描述
我正在从应用程序中保存文件,并具有以下保存窗口:
I'm saving files from the Application, and have this save window:
在这里按下确定"按钮,我使用了下一种方法:
Here to press "OK" button I used next method:
Robot robot = new Robot();
robot.keyPress(KeyEvent.VK_ENTER);
robot.keyRelease(KeyEvent.VK_ENTER);
在此窗口之后,Java加载应用程序将其打开:
After this window Java Loading application to open it:
在此之后,我有了这个窗口,以前的代码在这里不起作用,我无法按Enter: 谁知道如何在最后一个屏幕截图上单击运行"?
And After this I have this window and previous code doesn't work here, I can't press Enter: Who know how to Click on "Run" on the last screenshot?
推荐答案
我认为再次使用Sikuli会容易得多.您可以使用最简单的hello world示例- http://doc.sikuli来实现. org/tutorials/helloworld/helloworld-win.html
I think again it will be a lot easier to use Sikuli for the job. You can do it with the simplest hello world example- http://doc.sikuli.org/tutorials/helloworld/helloworld-win.html
这篇关于WebDriver单击"Java窗口"的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!