write vbscript on veb applications in qtp with exapmles?



write vbscript on veb applications in qtp with exapmles?..

Answer / nanda

Do u want simple script....

For Login ....

browser("XXXX").page("XXXX").webedit("hgshad").set "hdsfajf"
browser("XXXX").page("XXXX").webedit("dsadsagd").set "dlskajdl"
browser("XXXX").page("XXXX").webImage("dasada").click

to count No. Of Links in WebPage..

set objlink = description.create
objlink('html tag").value = "A"

set n = browser("XXXX").page("XXXX").childobjects(objlink)

c = n.count

msgbox c

like this we write script for testing web applications..
these are the sample scripts only...

If any queries..
nanda.dreddy@gmail.com

Is This Answer Correct ?    0 Yes 0 No

Post New Answer

More QTP Interview Questions

Please let know the scripts for counting number of repeated letters in the word. Note repeated letter should not be count agian. Ex: If "Hello" is my word... l is coming twice.. it should count once and print... secong 'l' should not count again..

5 Answers  


i have to pass the testcases into userid anf password of gmail login page using functions you can take your own testcaseslike userdid should take only lowerletters it should not take special charactors and uppercase letters and password should take only numericvalues it should not take alphanumeric and alphabets

2 Answers  


Is it possible to run QTP scripts created in IE 6.0 in IE 7.0?

4 Answers   TCS,


write a script to validate the content in the web application. (do it by OR method) and (do it by Descriptive method by creating a description object..

0 Answers  


In real time whenever we found bug , after that where you send to that bug. send to T.Lead or Directly Developer. Plz explain me?

2 Answers  






What is the difference between property and method?

2 Answers  


What is quick test pro? What is a quick test professional?

0 Answers  


Hi all , I have installed the QTP 11.0 Whenever I am opening QTP that time if any open Internet Explorer I was getting message (Internet Explorer has encountered a problem and needs to close. we are sorry for inconvenience caused) and same way new browser also not opening. If you have any idea please let me know.

2 Answers   ME,


does test plan is in test strategy or test strategy is in test plan

2 Answers   Tanla Solutions,


HI ALL I AM WORKING AS A AUTOMATION ENGINEER FROM PAST 2 MONTHS IN QTP,MY QUESTION IS IF I OPEN THE BROWSER FIRST & THEN THE QTP LATER MY OBJECT SPY WILL NOT WORK,Y IT IS SO..IF U HAVE THE ANSWER PLZ MAIL ME AT AKSHAR.MYSORE@GMAIL.COM

8 Answers   Infosys, TCS,


HOW CAN QTP AND TEST DIRECTOR CONNECTED TO THE DATABASE AND WHAT R THE OPTIONS?

0 Answers  


Hi What are re-usable actions in QTP? -Thank You

5 Answers   Siemens,


Categories