How will you send values to a cell in a webtable using QTP?
Answer Posted / amarendra kothuru
For WebTable object, you can retreive the cell data but
can't set any value directly.
To retreive data.
val = Browser().Page().WebTable().GetCellData(row,column)
To set the value.
If you want to set any value on cell, you can do it on its
child objects.
So make sure what is the child object of that cell i.e.
either WebEdit or WebCheckBox or WebRadioButton etc...
Using the method, you can set the value to that child objet.
Using ChildItem method, you can fetch the child object of
the cell.
Browser().Page().WebTable().ChildItem
(row,col,ChildObjClassname,index of the child
object).Set "abcd"
or
Set ChildObj = Browser().Page().WebTable().ChildItem
(row,col,ChildObjClassname,index of the child object)
ChildObj.Set "abcd"
E.g.
Set ChildObj = Browser("ab").Page("cd").WebTable
("de").ChildItem(row,col,WebEdit,0)
ChildObj.Set "abcd"
If the cell has more than multiple similar child objects,
then you need to take care of the object index.
Is This Answer Correct ? | 38 Yes | 6 No |
Post New Answer View All Answers
What is qtpro? What is quick test pro?
Explain advantages and disadvantages kdf?
How to use reporter.report event in qtp ?
How many types of recording modes in qtp? Which will be used when?
Approach for Installation,comaptibility,system testing
Tell me one scenario, the complex functionality you have automated in your project?
How many types of trigger events are there in qtp?
How to test fly out menu in qtp?
how did u use automating testing tools in ur job?
Explain the concept of object repository and how quicktest professional recognises objects?
What is object repository in qtp?
What are the key points to create a framework in QTP for oracle forms?
Key word driven framework
Hi Friends, Can anyone help me out in this one? In QTP, I am using Data Driver and want to parameterise multiple values (say 3 values ) for a field. How can I do it using Data Driver wizard? Plz mention it step-by-step. In the end after doing the needful, on opening the Data Driver window, how can I get number (i.e. 3) in the Parameterised column for that particualr value? Thanks a lot in advance.
banking project description for software tester