Hi,
My application has a list box whose contents are populated dynamically. So when I try to record and validate the list item elements, I am not able to validate a single particular element. Please let me know how to do it.
Validate text of list items in .NET framework
Re: Validate text of list items in .NET framework
Hi,
Could you please upload a Ranorex snapshot (not screenshot!) of the problematic listbox? Additionally, please post an example of xpath you are using for validation.
BTW, is the number of items (and their names) always the same, just loaded at different positions? In other words, what exactly you want to validate? Particular item(s) or entire list of items?
Could you please upload a Ranorex snapshot (not screenshot!) of the problematic listbox? Additionally, please post an example of xpath you are using for validation.
BTW, is the number of items (and their names) always the same, just loaded at different positions? In other words, what exactly you want to validate? Particular item(s) or entire list of items?
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
Re: Validate text of list items in .NET framework
Hi,
I could get the path only upto the listbox. (/form[@wpfnative='True' and @title='MainWindow' and @processname='Dataloader.View']/?/?/element/container/container/container[1]/list)
But I am not able to validate the elements inside the listbox.
I would like to validate the text of an element in the list box.
I could get the path only upto the listbox. (/form[@wpfnative='True' and @title='MainWindow' and @processname='Dataloader.View']/?/?/element/container/container/container[1]/list)
But I am not able to validate the elements inside the listbox.
I would like to validate the text of an element in the list box.
- Attachments
-
- test_snapshot1.rxsnp
- Snapshot of the app
- (180.21 KiB) Downloaded 47 times
Re: Validate text of list items in .NET framework
Go to Global Settings >> Plugins tab and here try to enable "Realize Items in Virtualizing Containers" option (under WPF section). Eventually, try to enable "Show All Elements" option. Then refresh Spy and check the list again. Hope this helps?
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
Re: Validate text of list items in .NET framework
It really solved my issue.
Thanks a lot.
Thanks a lot.
Re: Validate text of list items in .NET framework
You are welcome. Nice to hear it solved your problem.
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