How to Check Display Settings When a Test Starts (Windows 10)

Best practices, code snippets for common functionality, examples, and guidelines.
davepotts
Posts: 1
Joined: Tue Dec 11, 2018 10:35 am

How to Check Display Settings When a Test Starts (Windows 10)

Post by davepotts » Tue Dec 11, 2018 10:46 am

I'd like to have a test to check my display settings are 100% zoom at 1080p before running a test. I can open the display settings dialog in Windows 10 and from Spy identify it with:

Code: Select all

/winapp[@packagename='windows.immersivecontrolpanel']
When I add this to Studio and try to run the test I can open the display settings fine, but the Xpath doesn't find the elements. Any idea what I might be getting wrong?

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

Re: How to Check Display Settings When a Test Starts (Windows 10)

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

Hi,

What Ranorex version do you use? Do you have something in the WhiteList (e.g. your app under test or any web browser)? If yes, then you must add also SystemSettings process to the whitelist...
SystemSettings_WhiteList.png
SystemSettings_WhiteList.png (17.69 KiB) Viewed 143 times
Otherwise, the system settings and its elements are ignored by Ranorex (in favor of other whitelisted processes)!
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