Screen resolution

Ranorex Spy, Recorder, and Studio.
Dantas
Posts: 1
Joined: Thu May 24, 2018 9:37 am

Screen resolution

Post by Dantas » Thu May 24, 2018 9:51 am

Hi everyone,

We are currently using the trial version of Ranorex (latest version as of now) to evaluate it, and we are trying to get the full functionality and easiness of use of the tools! Now, we have reached a problem that is impeding continuation of the evaluation, and it is as follows:

A- Ranorex version: 8.1.1
B- Windows 10
C- Laptop monitor 1920x1080 ( no extra monitors)
1- Opening Ranorex studio
2- Using the template that already comes with the trial version (WordPressSample)
3- Click run test
4- Test stops working at one of the mouse clicks.
5- Test is cancelled
6 - Looking at the report we see that the "Screen dimensions" is set to 2400x1350!
7- We are constantly getting an error at the top right corner that says: "Different display DPI scaling values are in use. Please make sure all connected displays have the same DPI scaling value."

As a note that also might help, whenever we try to use Ranorex Recorder 8 and we start recording, Chrome opens and then the mouse always is pushed to the top left corner and although it has some movement slack ( when I move the mouse) then it always returns to that corner!

Can someone shed some light on what might be happening?

User avatar
Support Team
Site Admin
Site Admin
Posts: 11736
Joined: Fri Jul 07, 2006 4:30 pm
Location: Graz, Austria

Re: Screen resolution

Post by Support Team » Fri May 25, 2018 7:33 pm

Hi Dantas,

I recommend confirming your DPI is set to 100%. A higher DPI setting can throw off where Ranorex (or any object-based automation tool) thinks the element actually exists. This results in actions being performed at the wrong location (much like you describe).

You can also confirm the screen resolution during runtime by using the .NET code below in a Ranorex Code Module.

Code: Select all

Rectangle resolution = System.Windows.Forms.Screen.PrimaryScreen.Bounds;
Report.Info(resolution.Height + " x " + resolution.Width);
If you continue to experience issues, please provide a copy of the failed Ranorex Report (compressed) and a Ranorex Snapshot so we may better understand your environment and what may be occurring.

Note, your trial is fully supported and you can reach us here if you wish to troubleshoot this in a more private manner.

I hope this helps!

Cheers,
Ned
.
Image

User avatar
VanessaS
Posts: 18
Joined: Mon Jul 24, 2017 9:18 am
Location: Bavaria, Germany

Re: Screen resolution

Post by VanessaS » Tue Dec 11, 2018 3:14 pm

Hello, I'm resurrecting this thread because we're having a similar problem (runtime screen resolution different than the testserver or remote-desktop normally have) and I was wondering what the solution was.

Using your code, I receive the following:
screenresolution.PNG
screenresolution.PNG (1.99 KiB) Viewed 154 times
But we have set it to 1920x1080.

User avatar
odklizec
Ranorex Guru
Ranorex Guru
Posts: 4140
Joined: Mon Aug 13, 2012 9:54 am
Location: Zilina, Slovakia

Re: Screen resolution

Post by odklizec » Tue Dec 11, 2018 3:22 pm

Hi,

I think your only hope is to either increase the resolution on test server (which may not be always possible), or simply optimize your tests for running on lower resolution (ideally, directly on target system). There is not an automatic way to "fix" tests to run on different than designed resolution. I'm personally always designing tests on 'target' system, instead of designing them on local machine. This approach saves me from additional debugging of resolution/system-related differences ;)
Pavel Kudrys
Ranorex explorer at Descartes Systems

Please add these details to your questions:
  • Ranorex Snapshot. Learn how to create one >here<
  • Ranorex xPath of problematic element(s)
  • Ranorex version
  • OS version
  • HW configuration

User avatar
VanessaS
Posts: 18
Joined: Mon Jul 24, 2017 9:18 am
Location: Bavaria, Germany

Re: Screen resolution

Post by VanessaS » Tue Dec 11, 2018 3:42 pm

Normally, I'd agree, but the objects are so large that the test can't run properly. Everything overlaps everything else.