I Have web table shown below
----------------------------------------|
| orcut | GMAIL | NAUKRI |
|----------|---------|-------------------|
|HOT MAIL | MONSTER | VISIT FACEBOOK |
|----------|---------|-------------------|
|SKYPE ACC | IRCTC | GOOGLE |
---------------------------------------
Here i have 2 question friends..
1.i want to chick the link "VISIT FACEBOOK" is there or not
if it's there i want to click the link
2.here how to find the web table row or column count ...
don't write the excel or data table script here friends
..consider that it's a WEB TABLE
Answer Posted / kapil
rCount=Browser("title:=ABC").Page("title:=XYZ").WebTable
("name:=Links").RowCount
For r=1 to rCount
cCount=Browser("title:=ABC").Page("title:=XYZ").WebTable
("name:=Links").ColumnCount(r)
For c=1 to cCount
oCount=Browser("title:=ABC").Page("title:=XYZ").WebTable
("name:=Links").Childitemcount(r,c,"Link")
For obj = 0 to oCount-1
Set cObject=Browser("title:=ABC").Page
("title:=XYZ").WebTable("name:=Links").childitem
(r,c,"Link",obj)
If cObject.GetROProperty("innertext")="VISIT FACEBOOK" then
msgbox "Link is there"
cObject.click
Endif
Next
Next
Next
set cObject=Nothing
| Is This Answer Correct ? | 1 Yes | 0 No |
Post New Answer View All Answers
Qtp has been installed on my pc but recently ON opening it is giving this error PLEASE REPLY IT IS URGENT IT WAS WORKKING FINE QTPRO.EX THE instruction at "0x7.. ...". referenced memory at "0000....The memory could not be read... Awaiting QTP XPERTS REPly URGENT
Hi, How Accessibility checkpoint in QTP can be implemented in the test script?
What is method name to compare two XML files.
if anyone has idea of the interview procedure in covansys, plz send me a mail?
What are the disadvantages of recording test cases in qtp?
what is the frame work in J-meter?
What is the pros and cons between QTP and Rational Robot
Hi can anybody send me the QTP material, To my email ID: nuve1284@gmail.com ?
Write a script to verify font style and color of a windows object using descriptive programming
Pls can anybody send me the Recent Technical and Interview Questions Which were asked in IBM(QTP)Automation PLZZZZZZZZZ
What is the recovery scenario in qtp?
For which type of projects the iterative model is not suitable?
Hi All, How to Compare two strings character by character in QTP
what is the difference between data driver & data driven and driver script?
What is the syntax to call one script from another? And what can be the syntax to call one “action” in another?