Micro Focus QTP (UFT) Forums
cant create activex object for Mercury.ObjectRepositoryUtil in Windows 7 64-bit - Printable Version

+- Micro Focus QTP (UFT) Forums (https://www.learnqtp.com/forums)
+-- Forum: Micro Focus UFT (earlier known as QTP) (https://www.learnqtp.com/forums/Forum-Micro-Focus-UFT-earlier-known-as-QTP)
+--- Forum: UFT / QTP Regular Expressions (https://www.learnqtp.com/forums/Forum-UFT-QTP-Regular-Expressions)
+--- Thread: cant create activex object for Mercury.ObjectRepositoryUtil in Windows 7 64-bit (/Thread-cant-create-activex-object-for-Mercury-ObjectRepositoryUtil-in-Windows-7-64-bit)



cant create activex object for Mercury.ObjectRepositoryUtil in Windows 7 64-bit - gtamboli - 11-13-2012

Hi Ankur,

Could you please help me, while running the below code externally thru .vbs file, I am getting an error "ActiveX object can't create component for Mercury.ObjectRepositoryUtil":
my OS is Windows 7, 64 bit, (I googled this issue, I got info as Mercury.ObjectRepositoryUtil works fine for 32 bit windows OS)

Code:
Dim RepositoryTest,TOCollection,TestObject,PropertiesCollection,ObjDialog,Root

Set RepositoryTest = CreateObject("Mercury.ObjectRepositoryUtil")
RepositoryTest.Load "D:\Test\Resource_1.tsr"
' will Launch the application
intStartRow = func_Launch_The_Application()
intRowCnt = DataTable.GetSheet("Execution").GetRowCount
I want to use "Mercury.ObjectRepositoryUtil" object in my system using .vbs file, Is it possible to run it
i.e. if you have any patch info available, could you please reply/send it to me.
awaiting for your reply.

Thanks and Regards,
Gauravkumar.


RE: cant create activex object for Mercury.ObjectRepositoryUtil in Windows 7 64-bit - Ankesh - 11-14-2012

is it mandatory for you to use
"Mercury.ObjectRepositoryUtil" statement?

There is an alternate way to load object repository at run time.

RepositoriesCollection.Add "<Your .tsr File>

Regards,
Ankesh


RE: cant create activex object for Mercury.ObjectRepositoryUtil in Windows 7 64-bit - gtamboli - 11-14-2012

Hi ankesh,

yes, Its mandatory for me to use "Mercury.ObjectRepositoryUtil" as I am going to integrate it with JAVA applications. So if I call using .vbs file in JAVA, it will be better approach, (I don't want to run it inside QTP). I can use RepositoriesCollection.Add only inside QTP, not outside Sad .(I want to read OR using "Mercury.ObjectRepositoryUtil" as I can call it using vbscript.)

Regards,
Gauravkumar.


RE: cant create activex object for Mercury.ObjectRepositoryUtil in Windows 7 64-bit - Ankesh - 11-14-2012

Not sure abt the exact issue.

Can you try below suggestion and see if it works?

Add "<QTP Folder>\bin" path to your system PATH environment variable

Regards,
Ankesh