how to create user defined functions in QTP? can any one
expalin me with example..
Thanks in Advance for help

Answer Posted / chandu

u can create user defined functions by saving the file
as .vbs..just open notepad and write as below and save the
file with the ext .vbs

public function test
x=6
For i= 1 to x-1
x=i*x
Next
msgbox x
end function
then in QTP goto
File>settings>resources tab..add the .vbs file u created..
and then write call test.....in ur editor.

thanks
chandu

Is This Answer Correct ?    18 Yes 1 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Differences between quicktest professional (qtp) and winrunner?

880


Explain the types of properties that quick test learns while recording?

770


Explain the keyword driven framework for the window based application complete creation of library files,env file,test data,recovery file,excel file ,repository etc and as a test engineer how is ur approach

1805


What is the synchronization point in qtp?

742


When I click on a link in web page.Link should open in new window.can anyone please let me know the script for this ---Koti

2676


What are the benefits of qtp?

739


1--How many functions u develop 2--What is an array 3-- where is ur server 4--U involved in unit testing 5--how ur test the background colour using QTP

1748


How to perform cross platform testing and cross browser testing using qtp? Can you explain giving some example?

746


How can i get the image text that changes dynamically? Here i have used "GetROProperty", but it's not working. I used like Ex:Browser("webmail").Page("inbox").image ("captchaimage).getroproperty("innertext/text/value")

1615


Explain how you can delete excel file in qtp?

798


what is run-time data?

1916


when a test case is written how u test using qtp

1872


Is it possible to switch between recording modes during a test creation?

786


How do you open adobe acrobat file in QTP and do some testing on that file ?

835


What are parameterizing tests?

749