Micro Focus QTP (UFT) Forums

Full Version: How to recognize table row and column
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
I am testing a delete functionality. I have to delete one user among several users from the UI and verify it at the back end.

i think i have to use a script to delete the user whoever comes in the first and first column because if i script selecting particular user, i cannot re run that script second time. Because the user would already be deleted in first set of run and QTP will not find the user second time and will fail the script. So how can i script in this scenario ?? Please help...Sad
Can you please explain it further? I did not understand it quite well. Sorry.
You can get the 1st user run time (instead of passing the value from data table) and store it (If you need the deleted data in further verification). Then delete the 1st user and continue the rest.
You can use the ChildObjectItem method on the table and get the object in cell(1,1)
Code:
rCount=Browser().Page().WebTable().RowCount
for i=1 to rCount
    fname=Browser().Page().WebTable().GetCellData(i, 1)
'' Now you have the name stored in fname. Using this run your code to delete the user and iterate..
Next