Display results as :

Rechercher Advanced Search

Latest topics
» how to connect DB in selenium webriver
Fri Oct 06, 2017 4:09 pm by anbarasi

» How find any text in browser screen and click on it?
Thu Oct 05, 2017 2:02 pm by sandeepkommineni

» Selenium Webdriver
Tue Oct 03, 2017 1:35 pm by PiyushBiswas

» GRID setup tutorial.
Wed Sep 27, 2017 4:29 pm by johnyapp

» Drag & Drop Between Windows Using Selenium Driver
Wed Sep 27, 2017 2:10 pm by 26rondel

» Check if window is closed / verify input
Sat Sep 23, 2017 10:21 pm by brainstir

» How to work on pages with AJAX in selenium?
Mon Sep 18, 2017 6:08 pm by azharuddin

» pause test until user press a key like F2
Wed Aug 09, 2017 11:10 pm by djnforce

» Selecting the input for auto populating element
Sat Jul 29, 2017 7:53 pm by kdabbara


stored variable as an argument of uimap

View previous topic View next topic Go down

stored variable as an argument of uimap

Post by latim on Sun Mar 18, 2012 7:18 am

Hi all,

Being a newby in Selenium and new at the forum - I was trying to find similar problem discussed earlier here and, honestly, - no results. So seems I am not going to be a pain in the neck Smile

I have the following snippet of code in the IDE:

storeXpathCount | ui=empMngmt::gridRow() | empCount
  opening form, fulfilling fields and submitting - row is added to the grid
assertText | ui=empMngmt::gridCell(rowIdx=javascript{storedVars['empCount'] + 1}, colName=firstName) | SomeName |

by executing the first line - I am storing number of rows in a grid to the empCount variable - it works fine. And let say the empCount holds now 8.
by executing the last line - I am trying to assert if the expected value is displayed in a grid cell from the just added row (empCount + 1). The grid cell locator is defined in an ui map and ...
... the problem is that the
javascript{storedVars['empCount'] + 1}
is not actually recognized as javasript. The UI-Element tab shows:

current specifier maps to locator:
//div[@class="datagrid-body"]/table[javascript{storedVars['empCount'] + 1}]/tbody/tr/td[@field="firstName"]/div

when I need it to be


The question is - how to use an arithmetic operation with stored variables in ui-map's arguments?

Great thanks in advance!


Posts : 1
Join date : 2012-03-18

Back to top Go down

View previous topic View next topic Back to top

- Similar topics

Permissions in this forum:
You cannot reply to topics in this forum