Hi PLZ explain User Defined Functions in QTP with eample?
Answer Posted / amarendra kothuru
Functions - two types
1)Buitin - Prepared by QTP
2)User Defined - Prepared by programmer/tester
Syntan to creat User defined function in QTP
Function FunctionName(Parameter1, Param2,.....)
Statement1
Statement2
.....
.....
End Function
Example:
Function Bigger(value1, value2)
If value1 > value2 Then
Bigger = value1
Else
Bigger = value2
End If
End Function
Calling the function in the script
Result = Bigger(20,21)
Msgbox Result 'gives 21
| Is This Answer Correct ? | 2 Yes | 0 No |
Post New Answer View All Answers
whow much strong on VB and C?
How to use parameterization in qtp?
What is throw object?
How you can find the absolute value of the number in qtp?
Is it possible to switch between recording modes during a test creation?
any body plz send health care domain project to me with explanation any two modules on that project. mail_id: ranjith_99reddy@yahoo.co.in
write script for bitmap image?
what the difference between shared repository and per action repository?
How many add-ins comes by default with quicktest professional (qtp)?
Why script error occur in between recording in qtp?
How many add-ins comes by default with quicktest professional?
How the exception handling can be done using quicktest professional?
How QTP support all types of applications (platforms)?
How to find operating system information using the qtp script?
There are 10 rows in the datatable. How can we fetch 2 rows and then skip 3rd row. After that, pick 4th & 5th row and skip 6th row. Please share code