I am trying to count the number of rows in an HTML table using Selenium webdriver (Java.). The functionality is as below:
Text is iteratively entered into a search box from CSV file. Once, first text is entered and search results are displayed in HTML table, I have to count the rows in that HTML table.
The issue I am facing is that for every search text, the count of number of rows in HTML table displays same. I suspect that the rows are counted before the HTML table is refreshed for every search text and hence the count remains the same as the first text every time.
I guess the HTML table should be refreshed every time new text is entered in search box and then rows in table should be counted.
Can anyone suggest the possible solution to this issue? Can I temporarily disable the HTML element of webpage till the new text from CSV file is entered?