|
||||
|
|
||||
Thanks for your reply Kevin. Sorry for the late reply.
Here my problem is that I am not getting the text values of all the rows in the list.
eg. this is how I get the individual text values
Get Text xpath=//*[@id="accountsTabPanel"]/*[@id="accountsTabPanel-body"]/div[contains(@id,"partnergrid-")]//table/tbody/tr[1]/td[2]
Get Text xpath=//*[@id="accountsTabPanel"]/*[@id="accountsTabPanel-body"]/div[contains(@id,"partnergrid-")]//table/tbody/tr[2]/td[2]
..
..
Get Text xpath=//*[@id="accountsTabPanel"]/*[@id="accountsTabPanel-body"]/div[contains(@id,"partnergrid-")]//table/tbody/tr[n]/td[2]
how should I get all the text values in the list?
|
||||
|
||||
This method is slow and fills up the logs a bit, but is reasonable for small tables.
${cnt}= Get Matching Xpath Count //*[@id="accountsTabPanel"]/*[@id="accountsTabPanel-body"]/div[contains(@id,"partnergrid-")]//table/tbody/tr/td[2]
${values}= Create List
:FOR ${i} IN RANGE 1 ${cnt} + 1
... ${value}= Get Text xpath=(//*[@id="accountsTabPanel"]/*[@id="accountsTabPanel-body"]/div[contains(@id,"partnergrid-")]//table/tbody/tr/td[2])[${i}]
... Append To List ${values} ${value}
|
|
|
||
|
||||
Thanks Kevin, It works like a charm.
I just changed (...) by (\) in the for loop.
I will update the post with this solution.