Page 1 of 1

Invisible window not found

Posted: Thu Apr 06, 2023 9:40 am
by HansSchl
Hi,

I recently upgraded Ranorex from 10.1.3 to 10.5.4. Since then, a number of tests started to fail. One of the symptoms of failure is that Ranorex doesn't find invisible windows. Let me explain what I mean.

The AUT is a non-managed C++ application, using MFC. Its GUI is flexible and is sometimes modified during runtime. Some automatic tests verify which GUI elements are displayed and which aren't. Elements can be removed from the screen (effectively calling the API function DestroyWindow), or they can be hidden by calling ShowWindow(SW_HIDE) which leaves the window object in place but eoved the WS_VISIBLE flag, so that the window is no longer displayed on the screen. This question is about the latter scenario. I have verified this, using the "Spy++" tool from Microsoft.

The test does an "AttributeEqual" validation step, comparing the "Visible" attribute against the value "False". This worked before the Ranorex upgrade, and now fails with "No element found for path ... at step 'element[@windowtext='VU Meter']" when in fact I can see this invisible control in Spy++.

I believe this is a bug in the latest version of Ranorex. Comments welcome.

Best regards
Hans

Re: Invisible window not found

Posted: Mon Apr 10, 2023 2:43 pm
by rshah
After upgrade of Ranorex from 6.1.1.0 to 10.5.4, facing the similar challenge and the only difference is my window is visible but still getting "No element found for path '/form[@controlname='LoginForm']' at step '' after 1 attempts within 5s."
But the same code is working with 6.1.1.0 version.

I sent email to Ranorex support but no response on this problem, looks like they have some issue but not sure why no response from the team.

"Host.Local.FindSingle<Ranorex.Form>" throwing exception for me, even I tried to give 5 minutes of duration where as spy is able to find the control withing a second through same rxPath

Re: Invisible window not found

Posted: Tue Apr 11, 2023 8:40 am
by Stub
It's a bug I reported in Summer 2022, which got fixed only recently: invisible-controls-missing-from-v10-2-1-t21894.html

Re: Invisible window not found

Posted: Tue Apr 11, 2023 10:41 am
by HansSchl
What a long thread. I asked over there where to find this option.

Re: Invisible window not found

Posted: Fri Apr 28, 2023 9:46 am
by HansSchl
Thank you for your help @Stub. After a lengthy fight against hardware problems on the test system I can confirm that it works.

Best
Hans