Object Repository is a collection of object and properties with which QTP will be able to recognize the objects and act on it.
Methods of Object Repository –
-
Add – Adds an object repository file to the specified position in the collection.
-
Find – Finds the position of the specified object repository file.
-
MoveToPos – Moves the object repository file entry from the current position to the specified new position.
-
Remove – Removes the object repository that is located in the specified position.
-
RemoveAll – Removes all object repository files from the collection.
-
SetAsDefault – Sets the object repository files associated with the current action as the default files for all new actions.
Properties of Object Repository –
-
Count – The number of object repository files in the collection.
-
Item – Returns the path of the object repository located in the specified position.
Additional Reading
- Understanding object repositories in QTP 9.x series
- How QTP identifies objects?–Complete Refresher