Can we add the function library directly from scripting in
qtp instead of adding from resource tab?
Answers were Sorted based on User's Feedback
Answer / nath .t
Sorry for the small mistake in the above answer.
Set qtApp = CreateObject("QuickTest.Application")
qtApp.Launch
qtApp.Visible = True
qtApp.Open "C:\Tests\Test1", False, False
qtApp.Test.Settings.Resources.Libraries.Add "e:\Utils.vbs"
Is This Answer Correct ? | 8 Yes | 2 No |
Answer / nath .t
through script we can do
executefile "give the path"
Ex: executefile "d:\functionlibrary.vbs"
another way we can add to our script is AOM(Automated
object model)
first of all create Quick Test object than we can add with
that object.
Ex:
qtApp.Test.Settings.Resources.Add "Path of the library file"
like this we can add.
Is This Answer Correct ? | 5 Yes | 1 No |
Executefile "filepath.qfl" (we can do with qfl,vbs,txt extensions in this method)
loadfunctionlibrary "filepath.qfl" (we can do only qfl extension in this method)
Is This Answer Correct ? | 0 Yes | 0 No |
Answer / mohit
Naren,
Seems like u need to learn that adding a library and executing a library are two different tasks. In a laymen language, (that u seems to b more suitable for u) the difference is exactly what is in between loading a gun with bullets and firing the bullets. If u add something to ur resources, u may or may not use it in future. But when u execute something.. u command the control to execute it then and there without knowing even it is needed or not. So come prepared next time when u post something. Gud Day!
Is This Answer Correct ? | 0 Yes | 3 No |
Answer / naren
Hi Nath,
Please understand the questions first no hurry. Execute File
is the correct answer then again what is the need for adding
OR through scripting. Function Library means user defined
function(x.vbs) so Execute file is enough. The question does
not ask about adding Object Repository through scripting.
Is This Answer Correct ? | 1 Yes | 10 No |
What is the BPT(bussiness process testing ).and what is the main difference between BPT and QTP
3 Answers EDS, GL Noble Denton, IIST,
what is run-time data?
How to make qtp understand the difference amongst the same type of objects .suppose there are 5 check boxes in a page and I have to choose the 2nd one, how to do that through script?
what is keyword driven framework in qtp.
Can we do qtp testing without creating objects in Dbject repository? can we do it completely writing code i.e in expert view only. Are there any books for this?
Hi Friends, Every one is posting the Answers for the existing questions.Try to post the questions that are asked in Recent Interviews.It will be useful to the other Job seekers.
how can we preform retesting(DATA driven test) using function please gine the code for loginpage
Hi, I Need code to click the webbutton inside of webtable. I need to click a particular 'Edit' webbutton inside of webtable. For Example... Having 5 Rows and 10 Columns. 'Edit' webbutton are placed in 10th Column. I need to click the 3rd row 'Edit' button with unique value. Browser("....").Page("...").Frame("...").WebButton("btn_Edit ") I Tried with below code: Set objButton = Browser("...").Page("...").Frame("...").WebTable("...").Chil dItem(3,10, Webbutton,0).Click - Not working this code :( Anyone can help me to sort out this simple issue ???
Can any one brief some detail on how the shared and action object repository utilized/implemented in a real time project. I already know how to make shared object repositor by saving OR as .tsr extension..I wanted the actual concept of implementation...couple of live examples will be highly appreciated. Thanks
how can we compare descriptive programing with a regular expression
did you perform retesting(DATA DRIVEN test) using functions with out using datatable methods how can you perform retesting using functions
What is the file extension of the code file and object repository file in QTP?