Write a function which returns the addition of two numbers.
give the value of the numbers outside the function.
Answer Posted / sandeep guttikonda
1) Write the below code in notepad and save it as .vbs file.
Function Code:
Public Function Addition_Of_Two_Numbers (Value1,Value2)
Result = Value1 + value2
Addition_Of_Two_Numbers = Result
End Function
2) Open Quick Test Professional Functional Testing Tool
3) Go to File-> Settings-> Resources-> Click '+' symbol
under Associated Function Libraries: and upload the abouve
saved file.
4) Go to Expert View.
5) Write this VBScript Code:
Sum_Of_Two_Numbers = Addition_OF_Two_Number(3,4)
Msgbox "The Addition Of Two Numbers
= "&Sum_Of_Two_Numbers
This will display the answer 7 in a messagebox.
Note: You can change the constants 3,4 as you required.
Please let me know if you need any further info.
Thanks.
Regards,
Sandeep Guttikonda
Is This Answer Correct ? | 12 Yes | 4 No |
Post New Answer View All Answers
how will you load the test cases in ddt?
How you can find the absolute value of the number in qtp?
Can we run multiple QTP scripts one after the other without manual intervention? How?
Explain the parameter in qtp?
HOW AUTOMATE TEST SCRIPT ? what time it will do? after gneration of basic script or Any , Plz explain detailed?
With what extension you can save the list of tests in a file to run in test batch runner?
how to know no.of mails in our g mail by using vb-script
Discuss the QTP Environment?
What Folder Structure following in Keyword Driven Frame work?
What is use of object spy?
How is recording done when a application is over lapping the QTP application it gives a message object not recorded
after initiating one project for testing, when exacltly QTP tester role starts?
what is defenetion of kiran can u tell me plz CVS, SVN
How to analyzing test results using quicktest professional (qtp)?
how to write xml output check point bu useing descriptive programing .means without useing output check point