How to store xpath having a variable value in another value

Best practices, code snippets for common functionality, examples, and guidelines.
ankit26
Posts: 5
Joined: Thu Jun 16, 2016 11:35 am

How to store xpath having a variable value in another value

Post by ankit26 » Thu Jun 16, 2016 11:44 am

Hi

I want to click a button till I found a particular xpath and this xpath has been modified so it contains a variable. I tried using the while loop with the xpath but we cannot use a xpath in usercode. Can someone please help on how to do this.

Thanks

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

Re: How to store xpath having a variable value in another value

Post by odklizec » Fri Jun 17, 2016 9:53 am

Hi,

Could you please add some more details about your problem?

What Ranorex version do you use?
What kind of technology is your app (desktop, web, mobile)?
Could you please post a sample app/html code or at least a Ranorex snapshot (not screenshot) of the problematic element?
Please post your existing solution (at least sample solution) with non-working code.
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