如何在应用程序的特定位置(x,y)单击(应用程序在后台运行)?

huangapple 未分类评论47阅读模式
英文:

How to click in an application at particular location(x,y) (Application is running in background )?

问题

我想自动化执行Citrix应用程序,该应用程序可以通过Chrome浏览器访问。因此,我正在使用Selenium Web Driver在浏览器中打开应用程序。而且,重要的是我想在无界面模式下自动化(浏览器将在后台运行)。

我想实现以下任务:

  • 由于无法检查Citrix应用程序中的HTML元素,因此我们拥有的全部内容都是图像,可以通过图像检测进行自动化。

所以,我第一个问题是,是否可以在后台自动化Citrix应用程序(即不显示在监视器上)?

  • 如果可能的话,我可以使用Selenium来捕获后台应用程序的屏幕截图。
  • 并且借助Sikuli,我可以找到需要执行点击、输入和悬停等操作的对象位置。

现在,另一个问题是如何在后台运行的应用程序中点击特定位置?

我尝试过以下方法,但在我的情况下都没有成功:

  1. Robot类(失败原因:无法在后台工作)

  2. Selenium操作类(失败原因:需要Web元素)

  3. JavaScript执行器(失败原因:需要Web元素)

有人知道如何实现这个吗?

谢谢!

英文:

I want automate citrix application which can be accessed with the help of chrome browser. So, I am using selenium web-driver to open application in browser. And, the main thing is that I want to automate it in headless mode(Browser will run in background).

I would like to achieve following task :

  • As we can't inspect HTML element in citrix application, so all what we have is image, which can be automate through image detection.

So, my first question is that, is it possible to automate citrix application in background (i.e. without displaying on monitor) ???

-If it is possible then, I can use selenium to capture screenshot of application even in background.

  • And with the help of sikuli, I can find location of object where I have to perform action such as click, type and hover.

Now, another question is that How to click on particular location in the application which is running in background ????

I have tried following but none of them worked in my case :

1.Robot class (Failed due to : does not work in background )

  1. Selenium Action class(Failed due to : require Web-element )

  2. javascriptexecutor (Failed due to : require Web-element )

Does anyone know, how this can be done ??

Thank you !!!

huangapple
  • 本文由 发表于 2020年5月5日 19:51:42
  • 转载请务必保留本文链接:https://java.coder-hub.com/61612466.html
匿名

发表评论

匿名网友

:?: :razz: :sad: :evil: :!: :smile: :oops: :grin: :eek: :shock: :???: :cool: :lol: :mad: :twisted: :roll: :wink: :idea: :arrow: :neutral: :cry: :mrgreen:

确定