Using variable in Validate action

Ask general questions here.
Eamonn
Posts: 59
Joined: Wed Jul 16, 2014 9:30 am
Location: Dundalk, Ireland.

Using variable in Validate action

Post by Eamonn » Mon Feb 09, 2015 10:53 am

I am using a Validate action to check the text in an element.

Image

The Matched value is entered by the user and then appears in an element on another page. I am validating that this value is correct. The action shown in the image works fine, so the entered value an the previous page is validated as existing in the element on the second page.
I then began using a variable value for the user entry from a simple table on the first page. I wish to have the Validation action AttributeContains the Matched Text to the Matched Value in the element for each variable value used in the simple table. I have been adding a variable to the repository without success, then to the Matched Value and then to the Matched text without success for the action shown in the image. What is the correct method to achieve my objective?

krstcs
Ranorex Guru
Posts: 2683
Joined: Tue Feb 07, 2012 4:14 pm
Location: Austin, Texas, USA

Re: Using variable in Validate action

Post by krstcs » Mon Feb 09, 2015 6:04 pm

All you need to do is change the part where you have typed in the phone number "(W) 345-678-9999" to use the variable instead.
Shortcuts usually aren't...

Eamonn
Posts: 59
Joined: Wed Jul 16, 2014 9:30 am
Location: Dundalk, Ireland.

Re: Using variable in Validate action

Post by Eamonn » Thu Mar 19, 2015 11:47 am

krstcs, thank you for your reply. I had done as you suggested prior to posing my question but the action was failing. But, your suggestion prompted me to look more closely at what I was doing. I was creating the action correctly but I believe the variable value was the problem.

Eamonn