Warning on founding Excel popup ButtonOK

Ask general questions here.
lemoalh
Posts: 3
Joined: Wed Jun 19, 2019 4:07 pm

Warning on founding Excel popup ButtonOK

Post by lemoalh » Thu Jun 20, 2019 9:22 am

Hi SupportTeam,

I make my first steps in Ranorex and face the following questionning :
My test case open an excel file activate a macro which open a selection popup.
The Ok button is visible, clickable, but, although the tests is successful, the following warnings appear :

00:00.000
Warn Repository
Item 'TransparenceRepository.MicrosoftExcel.Popup_Selection.ButtonOK' could be found using its absolute path, but not using its relative path from the cached element of parent folder 'TransparenceRepository.MicrosoftExcel'. This can happen if either the item search timeout is too small or if items within a rooted folder do not share a common parent element. To fix this problem, first increase the item search timeout. If this does not help, create a separate rooted folder for this item or disable caching for the specified folder.


In attachment, you will find the snapshot and the compressed Ranorex solution.

Do you know how i could make those warnings disapear ?
Thanks in advance
H.
You do not have the required permissions to view the files attached to this post.

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

Re: Warning on founding Excel popup ButtonOK

Post by odklizec » Thu Jun 20, 2019 1:40 pm

Hi,

I think the problem is too generic xpath for OK button? Button with accessiblename 'OK' is basically system-wide element. At first, have you tried what error suggested (e.g. disabling cache for rooted folder)? Also, I would suggest to add Excel process name to Ranorex whitelist. This should make Ranorex to search the OK button just in the Excel-related dialogs.
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

lemoalh
Posts: 3
Joined: Wed Jun 19, 2019 4:07 pm

Re: Warning on founding Excel popup ButtonOK

Post by lemoalh » Fri Jun 21, 2019 1:21 pm

Hi Pavel,

Thanks for the quick answer.
Unfortunately, disabling the "app folder cache" didn't have impact on the warnings.
And Excel is already in the Whitelist, as chrome and explorer for the test to be completed.

You're certainly right when writing the problem is related to a too generic path.
Although, i don't see how to make the path more specific.

The most disturbing is that, when using item highlighting, the button is always find instantly...
I already tried to use SPY to specify the path, but the same path is always registered.

User avatar
Support Team
Site Admin
Site Admin
Posts: 12145
Joined: Fri Jul 07, 2006 4:30 pm
Location: Houston, Texas, USA
Contact:

Re: Warning on founding Excel popup ButtonOK

Post by Support Team » Mon Jun 24, 2019 3:02 pm

Hello lemoalh,

Thank you for uploading the Ranorex Solution and the Snapshot file. You are using the processname as a parameter in order to find the form element and I assume that this is the reason why this message appears for the OK button. The dialog with the OK button is a separate process, but might also have the processname Excel.

In the Ranorex Snapshot file the RanoreXPath to the OK button is:
/form[@title='Sélection']/button[@accessiblename='OK']

In your repository, the RanoreXPath is
/form[@processname='EXCEL']/button[@accessiblename='OK']

Please create another app folder with the path /form[@title='Sélection'] and move the OK button into the new app folder.

I hope that helps.

Regards,
Bernhard

lemoalh
Posts: 3
Joined: Wed Jun 19, 2019 4:07 pm

Re: Warning on founding Excel popup ButtonOK

Post by lemoalh » Fri Jun 28, 2019 1:43 pm

Hi Bernhard,

Your recommandations made the OkButton issue disappear ! :)
Thanks a lot for your support !

KR,
H.