Ranorex:2.1,win7
On my desktop ,there a 5 webdocuments ,within which only one's size, width>0,height>0
I'm trying to locate a webdocument when i use below Rxpath
@"/dom[@pageurl~' file://c:\\users\\"+username+@"\\AppData\\Local\\Temp\\.*\.html ' and @width='739' and @height='244' ] "
If i use it without @width & @height , it can find a webdocument , not which i need.
if i use it with width and height , it can not locate the webdocument. Is there sth wrong with my rxpath???
Width and height originates from what RanoreSpy captured.
i also used @width~'7.*' and @height~'2.*', it can not work
Find a webdocument by width and height
- Support Team
- Site Admin
- Posts: 12145
- Joined: Fri Jul 07, 2006 4:30 pm
- Location: Houston, Texas, USA
- Contact:
Re: Find a webdocument by width and height
The width and height of an element are currently not available as attributes in RxPaths. You can only use those attributes in RxPaths that are listed in the "General" tab of RanorexSpy when selecting an element.
However, you can simply get all dom elements in a list (Find("/dom[@...]")) and than go through the returned list and check the width and height of the individual elements.
Regards,
Alex
Ranorex Support Team
However, you can simply get all dom elements in a list (Find("/dom[@...]")) and than go through the returned list and check the width and height of the individual elements.
Regards,
Alex
Ranorex Support Team