How to use library files in QTP? how we can call these
files in to script?
Answer Posted / uday kumar_anem
We can load the external Library files by using 2 ways:
1. Choose Test > Settings > Choose Resources tab >
Choose + button so select the library file > browse and
select the library file > click Ok.
2. We can load the library files using Scripting:
Use executefile function to load library files.
Example:
executefile "C:\Documents and
Settings\ukumar\Desktop\Sample.vbs"
x=10
y=5
result=SumOfTwoNumbers(x,y)
msgbox(result)
'Code in External Library file(.vbs file).
'Public function SumOfTwoNumbers(a,b)
'Dim sum
'sum=a+b
'SumOfTwoNumbers=sum
'End Function
| Is This Answer Correct ? | 11 Yes | 1 No |
Post New Answer View All Answers
What are the two types of repositories available, explain them?
How to attach a file to TD?
How to use the object spy in quicktest professional 8.0 version?
How to recognise the webelement and verifying that webelement is enabled?
What is difference in global and action sheet in qtp?
What is the syntax to call one script from another? And what can be the syntax to call one “action” in another?
For which type of projects the iterative model is not suitable?
What is Associate Repository in QTP 9.2 ?
How Can I find the least value in a bunch of variables using qtp.. E.g.:- A = 210, B = 212, C = 60, D = 111 I don’t want to write bunch of lines for this…. Is there a way to get the result in one line…..
Hi all, I am using windows vista, I am in the process of learning QTP. When ever I try to work with insert mode in flight application , i am getting the error of 'Operation must use an update table query, fractional truncation(null) error. Can anyone help me regarding this?
What are the different types of checkpoints?
What is quicktest professional?
How can get count of list box?
can anyone tell me from where i can download qtp demo or crack version
What kinds of security (firewalls, encryptions, passwords, etc.) will be required and what is it expected to do? How can it be tested?