WinAppDriver icon indicating copy to clipboard operation
WinAppDriver copied to clipboard

Can only find PowerPoint Slide element when Inspect.exe is open

Open OhAye opened this issue 7 years ago • 3 comments

Hi,

I am using a Java Cucumber framework for running WinAppDriver but I've come across a strange issue with WinAppdriver where the driver will only assert the element is displayed if the Inspect tool is open. I've tried this on multiple machines and get the same results each time.

public boolean isSlide2ThumbImageDisplayed(){ try { driver.getKeyboard().sendKeys(Keys.ARROW_DOWN); driver.findElementByName("Slide two").isDisplayed(); return true; } catch (NoSuchElementException e) { return false; }

If Inspect.exe is not open you get a no element found exception.

OhAye avatar Jul 29 '19 13:07 OhAye

Hi @OhAye, is this the case for all apps - are our samples working as expected?

What does the WinAppDriver.exe report back?

hassanuz avatar Aug 07 '19 02:08 hassanuz

Hi, @hassanuz thanks for your reply. Yes, the samples work fine, I've only noticed this issue with PowerPoint. It looks to happen when you attempt to interact with the slides as in being able to sendkeys or assert if a slide exists. However, you can interact with the top-level elements just fine such as clicking file. I've added what WinAppDriver sends when it's unable to find the element with Inspect.exe not running. Let me know if you require anything else.

`POST /session/2DC978DC-AB59-4D42-9A40-3574C2C7E51A/element HTTP/1.1 Accept-Encoding: gzip Connection: Keep-Alive Content-Length: 49 Content-Type: application/json; charset=utf-8 Host: 127.0.0.1:4723 User-Agent: selenium/3.141.59 (java windows)

{ "using": "name", "value": "Title TextBox" } HTTP/1.1 404 Not Found Content-Length: 139 Content-Type: application/json

{"status":7,"value":{"error":"no such element","message":"An element could not be located on the page using the given search parameters."}}`

OhAye avatar Aug 07 '19 10:08 OhAye

Hey @OhAye ,

Sorry - didn't get a chance to follow up on this. Were you able to get this resolved? If you're still facing a similar issue, please try the latest v1.2 release.

hassanuz avatar Dec 18 '19 23:12 hassanuz