Can any one give me some basic VB script used in QTP ?As i
am new in QTP.Give sample VB script used in QTP? PLZ

Answer Posted / dhana

first of all u need to add Objects in u r Application on
which u want to perform Operations to Object repository.

For ex:u need to Add Browser,Page,Frame,Webedit
(Username,Password),webbutton objects to objectRepository
then once u write "Browser" in Expert view,QTP
automatically vl popup the Browsername so as for page and
for Subsequent objects also...


for ex:

Browser("Browsername").Page("Pagename").frame
("Framename").webedit("Username").set 12345

Browser("Browsername").Page("Pagename").frame
("Framename").webedit("Password").setsecure asdahsxcasjd2362

Browser("Browsername").Page("Pagename").frame
("Framename").webbutton("Login").click

Is This Answer Correct ?    4 Yes 1 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Approach for Installation,comaptibility,system testing

1711


Hi Friendss..., can any body help me.. 1. Tell me your achievements(Technically)..? 2. Tell me your strengths(Technically) and weakness(Technical)..? 3. Why are you looking for change..?

1422


Where you are storing your script?

636


Dear sir, i want to perform a QTP automated testing for mechancial engineering software like msc adams, msc nastran this softwares will help for mechanical engineering design analysis>> i know oad runner win runner, test director, QTp>> but i dont know how to use for automation

1587


How software tester can use constants and variables in scripts?

1689






Tell some commonly used Excel VBA functions?

605


How you debug your script?

576


In qtp is it possible to check broken links of a page?

590


How will you declare a variable in qtp?

558


What is data driver in qtp? Where we use it?

571


How are actions and functions different in QTP?

660


What is Test Fusion Report in QTP?

622


how to use the QTP choose the data from oracle? e.g. i input the identity card NO. this will be add new record in the database ,and now i want get this record's prime key.

1326


How many tabs are available in debug viewer pane?

649


What is data driver in qtp?

578