We will be focusing on 2 methodologies to achieve our target.
Approach 1:-
Using “ObjectRepositoryUtil Object“
Using “ObjectRepositoryUtil Object“
ObjectRepositoryUtil(ORU):-By using this object we can work with object Repository files (Local/Shared) from outside of UFT.
We need to use “ExportToXML” method of ORU object.
![]() |
ExportToXML Method |
'Creating the ObjectRepositoryUtil to work with OR
Set objORU = CreateObject("Mercury.ObjectRepositoryUtil")
'Exporting the OR into new XML file
objORU.ExportToXML"C:UsersTestMe.tsr","C:UsersTestMe.XML"
'Destroying the object
Set objORU = Nothing
Note:-
Incase TargetFile, already exists UFT will give an error.
Approach 2:-
Using Object Repository manager
Using Object Repository manager
1.Open Object Repository manager
Resources ->Object Repository Manager
![]() |
Object Repository Manager |
2.Open the OR
File ->open
3.Export to XML format
File ->Export to XML
![]() |
Export to XML |
After Export we will get the information regarding the objects Exported from OR
![]() |
Export Result |
One reply on “How to convert Object Repository into XML format?”
I am on UFT and it is not working 🙁 could you please let me know what is equivalent for UFT?