Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...


How to call the userdefined functions to script? If i am
stored 'add()' function in Library functions folder. i want
to cal that function in my script.

Answers were Sorted based on User's Feedback



How to call the userdefined functions to script? If i am stored 'add()' function in Libr..

Answer / murali raju

Instead of add name put the add1 as ur function
name...because add is keyword

Function add1(a,b)
c=a+b
add1=c
End Function 'put the function .vbs file and save it c
drive with the file name addition.vbs

write the below script in ur qtp

ExecuteFile "c:\addition.vbs"
x=add1(2,4)
msgbox x 'it will be prints 6 in the msgbox

Is This Answer Correct ?    1 Yes 0 No

How to call the userdefined functions to script? If i am stored 'add()' function in Libr..

Answer / pramod

But your code is giving me acess denied error

how to save the function as .vbs thorugh QTP or VB

Is This Answer Correct ?    0 Yes 0 No

How to call the userdefined functions to script? If i am stored 'add()' function in Libr..

Answer / murali raju

Hello...pramod..Put the function in notepad and save
as .vbs extension then call through the above execute file
statament in qtp ...ok.na..

Is This Answer Correct ?    0 Yes 0 No

How to call the userdefined functions to script? If i am stored 'add()' function in Libr..

Answer / umesh

Save your functions in a notepad and save it as a .vbs file.

Under Test Settings - Resources tab, Associate your .vbs
file as a Library.

Call the .vbs file as a header in your script and use all
the functions.

Is This Answer Correct ?    0 Yes 0 No

Post New Answer

More QTP Interview Questions

what is the Exact Meaning of Environment Variables?

2 Answers   Semantic Space,


What is data driven testing in QTP?

11 Answers   Agile Software,


WHAT IS ETL TESTING.......

2 Answers  


HI. Plz Clarifie my doubt,having 2+yrs experience in Testing , But My accedamics(Xth,INTER) are Less than 60%, But B.Tech 72%. It creats any problem , When i change to any MNC. plz tell me......... lot of friends told it's a problem, Some people says NO problem, What .............

3 Answers  


i need the word "good morning" to be displayed by default whenver we click upon the blank test while opening the qtp. Could you please answer...

7 Answers  


Hi,All How to create a link in excel sheet using qtp

0 Answers  


Hi, Can anyone please tell me how to connect the QC with QTP using QTP script? Thanks in advance

0 Answers  


what is Synchronization point in QTP?Can anybody give a perfect example on it Thanks in advance

5 Answers  


what is the mediater between qtp and application/project in automation testing?

1 Answers  


hello everyone, can anybody please tell me what are the different recording modes of QTP, and where these recording modes are present in QTP 9.2. Thanks in advance, Gaytri

7 Answers  


What is diff between SDLC AND STLC?

1 Answers   Nokia,


can anyone please tell me which is the best institute for learning QTP and Automation Testing tools in hyderabad with realtime examples and scenarios...I heard about many institutes in Ammerpet hyderabad i.e Suresh Reddy's Smart Solutions, Ashwin Palaparthi's Tech Teach,SUNNYSOFT, SITE institute, I-VINTAGE, siritechnologies and sriven institute..pls suggest me which to choose for learning QTP....Which institute has fasttrack option?

2 Answers  


Categories