Set a=description.Create
a("name").value="Google"
Set b=description.Create
b("Title").value="Google"
Set c=description.Create
c("micclass").value=" webedit"
'c("name").value="q"
'c("type").value="text"
'Set d=description.Create
'd("name").value="q"
Set e=description.Create
e("micclass").value="webbutton"
e("name").value="Google Search"
Set h=description.Create
h("name").value="qtp - Google Search"
Set desc=description.Create
desc("micclass").value="webelement"
desc("type")="qtp"
Set l=description.Create
l("title").value="qtp - Google Search"
'invokeapplication"C:\Program Files\Internet
Explorer\IEXPLORE.EXE","http://www.google.co.in/"
invokeapplication"C:\Program Files\Internet
Explorer\IEXPLORE.EXE"
Browser(a).Page(b).WebEdit(c).set"qtp"
Browser(a).Page(b).WebButton(e).click
set z=Browser(h).Page(l).childobjects(desc)
i=z.count
print i
'For j=0 to i -1
' m=z(j).getroproperty("text")
' msgbox m
' print m
'
'Next
hi guys this is anil. i am beginner in advance qtp. i am
trying to write script for searching web element (QTP)in
google. i have posted a script plz check it. send me
solution how to write scripting for search and counted no
qtp word in google search . plz tell me the solution ASAP
Answer / Kapil Kumar Vishnoi
It seems like you are trying to define various descriptions for a QTP script that opens Google, clicks the search button, and then searches for the word 'qtp'. However, the script is incomplete and does not execute the search or count occurrences of 'qtp' on the page. To make it work, you can modify your script as follows:n
1. Add a function to open Google: invokeapplication"C:Program FilesInternet ExplorerIEXPLORE.EXE""http://www.google.co.in/"
2. Add a loop to search for the word 'qtp' and count its occurrences: nFor j=0 to i -1n m=z(j).getroproperty("text")n If m contains "qtp" thenn print "Found qtp"n End IfnNext
| Is This Answer Correct ? | 0 Yes | 0 No |
when do you stop testing?
How we will do DataBase testing through Qtp application, i know two things 1)Import date from sheet2)Database Check points. But Interviewr asked me How to Run Queries from Qtp Application?Plz Any Body Exlain about Data Base Testing.Urgent.........Advanced Thanks
why do you choose testing?
Explain automated testing?
hi frens, i need ur help if nebody had worked or workin on online banking projects n online job portals ..frens cud u pls gimme the realtime examples for critical bugs, high severity n low priority bugs high severity n high priority bugs low severity n low priority bugs high severity n low priority bugs related to banking n job portal
content of test status report
Explain the tasks involved in planning and control.
there is a function called changevalues(x,y)inside this function x=x+y/2 y=y+x+5 end so i am calling function in one program as changevalues(y,x) what is the output if x=2 and y=10(ignore exact programatic statements) please can any one provide me answer for this immediately
how do you convert use cases into test cases?
What test plans consists of?
What is SDLC and STLC? In analysis phase of SDLC, what exactly the testers will do?
What are the advantages of designing tests early in the life cycle?