How to load the object repository at run time?

Answer Posted / sanurajps

hi,

One of the new feature of QTP 9.2 is Dynamic Management of OR.

>>ADD - RepositoriesCollection.Add("D/OR/test.tsr")
-- it will add the 'test.tsr' file during the run time

>>FIND - Pos = RepositoriesCollection.Find("D/OR/test.tsr")
-- it will return a numeric value to the variable 'Pos' this
is nothing but the index value of the specified file

>>MOVETOPOS - RepositoriesCollection.MoveToPos(2,5)
-- here 2 is the current index and 5 is the new index
position. In this case it will move 2nd item to 5th position

>>REMOVE - RepositoriesCollection.Remove(5)
--it removes the 5th object repository file from the OR

>>REMOVEALL - RepositoriesCollection.RemoveAll
--it removes the full items from OR. Makes object repository
empty

>>COUNT - no = RepositoriesCollection.Count
--stores the number of repository items to 'no'

>>ITEM - desc = RepositoriesCollection.Item(4)
--returns the path of the 4th object repository file.


Thnx
Sanu

Is This Answer Correct ?    13 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

hi can any body give me a script for creating a modularity or keyword driven framework..i am working as a qtp tester for 2 months but still i am not exposed to framework in my company

1418


whow much strong on VB and C?

1477


How is the Bitmap checkpoint different from Image checkpoint?

619


How to connect the remote desktop using QTP 9.2 explain the method or procedure?

2790


write a script to verify links on any web page by using descriptive method by creating a description object (give a filter condition only link) ... need to verify expected like name by reading

1479






What are the main differences of qtp and win runner?

589


What are the different kinds of test steps?

563


Have you used xml check point in your project? How?

539


How to analyzing test results using quicktest professional?

560


How can I import environment from a file on disk?

531


How to handle dynamic objects in quicktest professional (qtp)?

542


With what extension you can save the list of tests in a file to run in test batch runner?

557


Generic function to search for the unique link in webtable and click on it

2479


Explain the difference between check point and output value?

486


What is regular expression?

573