Identifying Row for dynamic grid/ Table
I have an application generates table/grid and loads dynamically every time and I need to get the count of the number of rows. But the table rows change everytime.
The underlying technology used is HandsonTable (JSpreadsheet) to generate the same.
Suppose I give the XPATH – .//*[@id=’dgrid’]/div/div/div/div/table/tbody/tr
Though the grid has 50 rows the Xpath for the last row shows as mentioned in the XPath
Comments/Suggestions are welcome.
Have anyone come across automating JSpreadsheets or Applications developed in HandOnTable.
Thanks In Advance
Hey SD, Thanks for asking a question that has good amount of information to work on. Coming to your question, there is a sample table from HandOnTable https://handsontable.com/examples.html?headers
Here if you try to get the xpath of last row, it does return 22th row and similary for al rows it returns the right XPath.
If your table loading dynamically? May be if you scroll down then only all the rows will appear?
Yes Virender the table in my application looks pretty similar. Yes table loads in DIV to get all the rows I scroll down using actions. But the Table row count and actual count varies.
I am unable to get the pattern.
For example, the dynamic grid has 129 rows of data. So the XPATH for the same would be as shown below:
We can only come to conclusion on XPATH when there is a pattern or else for different rows of data XPATH would fail.