What is the difference between functions and actions in
QTP?
Answer Posted / deven
♦It returns single value.
♦ we can call functions within actions but we can't call
actions within functions
♦ Generally functions are saved with ".vbs" extension
whereas actions will save with ".mts".
♦ Every Action will have its own Datatable whereas function
does not.
♦ Action can have a object repository associated with it
while a function can't. A function is just lines of code
with
some/none parameters and a single return value while an
action can have more than one output parameters.
♦ Action can contain Object Repository, Data table, Active
screen etc. whereas function do not have these features.
♦ Action is internal to QTP whereas Function is just lines
of code with some/none parameters and a single return value.
♦ Action can/cannot be resuable whereas functions are
always reusable.
♦ Action Parameter have default values whereas VB script
functions do not have any default values.
♦ Action parameter type are byvalue only where vbscript
functions can be passed byref.
♦ Action can have multiple output(returning) values whereas
function can return only single value.
Is This Answer Correct ? | 1 Yes | 0 No |
Post New Answer View All Answers
What are the things(properties, and other details) will be recorded while recording an object using normal recording?
What is qtpro? What is a quick test professional?
What is quick test pro? What is a quick test professional?
What is the difference between a Function and Procedure in QTP?
What is active screen?
What is the file extension of the code file in qtp?
I want to grow as a Automation Engineer,Kindly help me in clearing my interview that what interviewer looks for as a Automation Engineer. I am having three years of experience in testing.
what is the difference between built-i function and In-built function?
what QTP Options do you know?
How to use transactions in qtp?
Define virtual object?
What is action? How many types of actions are there in qtp?
In Test Directory, What are the contents in test case designing? if you prepare in excel sheet how u use thrw Test Directory?
Describe the differences between functions and actions in UFT?
What is the difference between the design-time and run-time data tables?