Page 1 of 1

rx-path changes wether I start the app or ranorex does

Posted: Wed Sep 02, 2020 8:08 am
by ovin
Hi all,

I use Ranorex 9.3.2 at the moment, but this problem also occures with older versions.

I have to test a java-application. The problem is, that the rx-path changes wether I start the application or ranorex does. You can see the difference in the two ranorex-snapshots in the zip-file.

Testing ist very simple. If I start the app by clicking on the desktop icon ranorex path looks like this:

Code: Select all

/form[@title='Anmeldung']/container[@type='Composite']/container[@type='Composite']//text[@caption='Benutzerkennung:']
And this ist fine to me!

If Ranorex starts the app the same way (clicking on the desktop icon) the rx-pathes look like this:

Code: Select all

/form[@title='Anmeldung']/element/element[@class='SWT_Window0']/element[@instance='0']/element[@instance='0']/?/?/text[@caption='Benutzerkennung:']
And this ist NOT OK!

The settings for the solution are:
  • Enable filtering on the Fx scenegraph = True
  • Refresh java window after injection = True
  • Show SWT custom data properties = True
  • Use Java SWT legacy automation mode = False
Changing these settings doesn't solve the problem.

Why does the path change depending on who starts the app?

Regards
Oliver

Re: rx-path changes wether I start the app or ranorex does

Posted: Fri Sep 04, 2020 6:58 am
by odklizec
Hi,

This is really weird. Are you starting Ranorex Studio as an administrator? If no, try it. if yes, then try no to ;)

Another thing you might try is to start the app via Run App command, instead of clicking the desktop icon. And in Run command, simply specify the same command line as used in desktop shortcut.

Re: rx-path changes wether I start the app or ranorex does

Posted: Fri Sep 04, 2020 7:03 am
by ovin
Perhaps I should give further information:

Presently we use Win 10 and JRE 1.8.0_221-b11, but i dont know if these Versions causes the problem.

The most importent difference between the two given path examples obove is, that the first one is faster than the second one. Also I can see some element IDs in the first example.

My read is Ranorex influences the starting process of the application, but I dont know how.

Please ask, if you need further informations or tell me if you have any ideas.

Regards
Oliver

Re: rx-path changes wether I start the app or ranorex does

Posted: Fri Sep 04, 2020 7:26 am
by odklizec
Hi,

The app started with Ranorex looks definitely different in Spy. There are missing properties in the app started via Ranorex...
JavaApp.png
So please try the steps I mentioned in my previous post (running Studio as administrator/not-administrator and runing app via Run app command).

Re: rx-path changes wether I start the app or ranorex does

Posted: Fri Sep 04, 2020 7:36 am
by ovin
Yes, it is weird!

It doesn't make a difference starting Ranorex in admin-mode or not. Same behavior.

To explain the problem I used the click on the desktop icon. Normally I use Run App command in my test-projects, and in this case there are no start parameter. But it doesen't make a difference starting the app by mouse click or by Run App command.

And to make it a little more weird: There are few apps in my solution. Let the one we talk about call App A. There is an other App B with the same conditions. If Ranorex starts App B it works, but if Ranorex starts App A it doesn't.

Regards Oliver

Re: rx-path changes wether I start the app or ranorex does

Posted: Fri Sep 04, 2020 7:49 am
by odklizec
Hi,

I'm afraid, that this kind of issue will require an assistance of Ranorex support and examination of the app under question. Which means that you should create a support ticket and request a remote session with Ranorex folks.

Please create a support ticket here:
https://www.ranorex.com/support-query/

BTW, have you tried to reproduce the problem on another computer?

Re: rx-path changes wether I start the app or ranorex does

Posted: Fri Sep 04, 2020 8:29 am
by ovin
Yes, same behavior on other computer.

I will create a support-ticket - next week.

Thank you!

Re: rx-path changes wether I start the app or ranorex does

Posted: Wed Sep 30, 2020 9:33 am
by ovin
Hello again,

it seems as if our application needs some time to initiate and Ranorex tries injecting itself too quickly. If I use a generous delay directly after Run Application object recognition works as expected.

Thanks to Ned from the Ranorex-Support-Team and bye...