How to load a object repository in QTP during runtime?
Answers were Sorted based on User's Feedback
Answer / nath .t
we can add object repository at runtime
Two ways are there u can add
1. when u write below syntax in Action1
Syntax: RepositoriesCollection.Add(Path)
Ex: RepositoriesCollection.Add(E:\OR\ObjRes.tsr)
if write in Action1 it will automatically add the Object
Respository to the Action1
(i.e Edit Menu-->Action-->Action Properties-->Associate
Repository tab) at runtime.
no need to add the object repository before running.
2. Add the object repository at runtime by using AOM
(Automated Object Model)
Ex:
Dim qtAppn
Dim qtObjRes
Set qtAppn = CreateObject("QuickTest.Application")
qtAppn.Launch
qtAppn.Visible = True
qtApp.Open "E:\Test\Test2", False, False
Set qtObjRes = qtApp.Test.Actions
("Login").ObjectRepositories
qtObjRes.Add "E:\OR\ObjRes.tsr", 1
The above example Add the Object Repository(ObjRes.tsr) to
the "Login" action in Test2.
Here also no need to add the object repository in Test2.
Is This Answer Correct ? | 67 Yes | 5 No |
Answer / guru
StrPath = "D:\FrameWork\Repository\GoogleHomePage.tsr"
RepositoriesCollection.Add(StrPath)
Is This Answer Correct ? | 25 Yes | 2 No |
what is Unicoad Compatibility ???? HOw does this makes a diffrence from Winrunner.???
what are the Common Problems in S/w development process
What In-string function will do?
How to connect to oracle(sqlserver) database to QTP
which command u will use to access the application through descriptive programing?
How can we test an XML using QTP? I have been to an interview, where they have given me an XML which had 15 values and they have given those values on a separate page. They asked me to write a QTP script to check the XML is having those particular 15 values.
Is QTP Supports SWT applications? If yes, can you write a sample script for opening a new package in eclipse.
what is the difference between QTP 8.0 & 9.0?
Did QTP prove efficient for your project? Yes or No, explain?
hi how could i get installation guide for QTP 9.0 on XP help me for this !!!!!
Can we record a video in qtp recording??
1. What is extense of Result file in QTP?