Edit a record in datagrid
There is a datagrid. A record is inserted in that datagrid. Now I want to edit the inserted record in the datagrid. How can i do that with QTP?
We have an option of "edit" I just want to know how to capture the inserted record so that same record can be edited.
Last edited by malhotratanu; 12-30-2012 at 10:35 PM.
Using ChildItem to first click on the "Edit" of the inserted record,
I hope the record now display value in editable fields with WedEdits.
Then update the values in that record.
We can help you better if you can show your application screenshot or snippet of the code you tried.
hi uday, thanks for the prompt response. Details are given below
Edit button/Delete Item1 Details1
Edit button/Delete Item2 Details2
Edit button/Delete Item3 Details3
Edit button/Delete Item4 Details4
Above “Items” is a dropdown list. We select an item, click Add and it gets added in the grid above. Deleted item again gets visible in “items” dropdown. But if an item is displayed in datagrid then it should not be visible in Items dropdown. Now the grid is dynamic.
I want if I add Item4 then after I want to edit item 4 only. How it can be done.
Here is my approach:
set oChild=B().P().WT().ChildItem(iRow,1,"WebButton",0 )
Once you click on the Edit button, now update with new values.
thanks uday. i'll try ur approach and will let you know if it worked out or not.