row[] in xpath found cell, but what is row-nbr?

Ask general questions here.
User avatar
woha
Posts: 11
Joined: Wed Mar 06, 2019 12:56 pm

row[] in xpath found cell, but what is row-nbr?

Post by woha » Tue Feb 18, 2020 2:57 pm

Question is simple, but i found no solution how to get the found row-nbr.

Sample from Repository:
?/?/table[@automationid='m_listUsers']/container[1]/container[2]/row[]/cell[@text=$colWinUser]
This will find my $colWinUser on row Line 22 says the spy.
What i need is the "22" into a variable to get other columns in same row nearby. Thats what i need.

i searched the forum over 2 hours. Its not easy to know what to search for..hmmm.

Any ideas are welcome.

cu
Wolf

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

Re: row[] in xpath found cell, but what is row-nbr?

Post by odklizec » Tue Feb 18, 2020 3:05 pm

Hi,

Please post a Ranorex Snapshot (NOT screenshot) of the table in question. Without this info, it's impossible to tell what to do.
Generally speaking, it should be possible to get the value you want via GetValue action (pointing to the returned element and attribute returning row number).
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

User avatar
woha
Posts: 11
Joined: Wed Mar 06, 2019 12:56 pm

Re: row[] in xpath found cell, but what is row-nbr?

Post by woha » Wed Feb 19, 2020 10:28 am

All fine now. Found a way to get the other cells in this row. Sometimes it is better to sleep over a problem :lol:
Thanks for answer Pawel
cu
Wolf

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

Re: row[] in xpath found cell, but what is row-nbr?

Post by odklizec » Wed Feb 19, 2020 10:49 am

Hi,

Nice to hear you found the solution. I know this "sleep-on-it" thing very well too ;)
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