In what situations is an element 'Invalid'?
-
- Posts: 5
- Joined: Tue May 16, 2017 4:46 pm
In what situations is an element 'Invalid'?
I was using Ranorex spy to highlight some elements on our UI and noticed that it no longer worked to highlight tree items. So, I clicked on the tree to find out why and I see this (Image attached). The tree items are invalid, why is this? And how can I get them to be valid again?
- Attachments
-
- Screen Shot 2017-07-04 at 4.03.21 PM.png (37.36 KiB) Viewed 1097 times
Re: In what situations is an element 'Invalid'?
Hi,
Typically, an element becomes invalid when it's no longer available in UI. In case of tree elements, it may happen if the content of tree is scrolled. Simply put, the no longer visible tree items are not in memory anymore. Usually, it happens with lazy loaded lists (tree elements, combo boxes, etc).
Typically, an element becomes invalid when it's no longer available in UI. In case of tree elements, it may happen if the content of tree is scrolled. Simply put, the no longer visible tree items are not in memory anymore. Usually, it happens with lazy loaded lists (tree elements, combo boxes, etc).
Pavel Kudrys
Ranorex explorer at Descartes Systems
Please add these details to your questions:
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
-
- Posts: 5
- Joined: Tue May 16, 2017 4:46 pm
Re: In what situations is an element 'Invalid'?
This happens when any tree element is clicked. It is still on the screen, why would it not be considered visible or in memory?odklizec wrote:Hi,
Typically, an element becomes invalid when it's no longer available in UI. In case of tree elements, it may happen if the content of tree is scrolled. Simply put, the no longer visible tree items are not in memory anymore. Usually, it happens with lazy loaded lists (tree elements, combo boxes, etc).
Re: In what situations is an element 'Invalid'?
"Invalid" means that the UI actually changed since the element has been found by Ranorex and the element is no longer connected to the UI. This typically happens if you track an element with Ranorex Spy, then change something (substantially) in the application, e.g. navigate to another web page or the UI is refreshed.
You did not mention the exact sequence of steps to reproduce this, nor did you post a Ranorex snapshot of the UI. Could you possibly provide both?
Besides, if that happens while using Spy, you can try to refresh the element tree by clicking the toolbar item or pressing F5. Ranorex Spy does not refresh automatically, unless you track another element.
Regards,
Alex
Ranorex Team
You did not mention the exact sequence of steps to reproduce this, nor did you post a Ranorex snapshot of the UI. Could you possibly provide both?
Besides, if that happens while using Spy, you can try to refresh the element tree by clicking the toolbar item or pressing F5. Ranorex Spy does not refresh automatically, unless you track another element.
Regards,
Alex
Ranorex Team