Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

jacob - Can't co-create object

My environment is Java 7, on Windows 7 - 64 bit. So here's my requirement and procedures I followed

  1. I wanted to execute a library called test.dll from Java
  2. I first downloaded the latest version of jacob, and put them within a folder, which is included in the Windows environment variable PATH.
  3. I registered the test.dll using regsvr32.exe under C:\Windows\SysWOW64 (it was successful!)
  4. I am running jacob from a webapp, so I made sure that WEB-INF/lib has jacob.jar in it.
  5. I also set a java System property - -Djava.library.path=c:/dev/jacob/jacob-1.17-x64.dll (This is where I have kept the jacob-1.17-x64.dll)

still I am facing

com.jacob.com.ComFailException: Can't co-create object
    at com.jacob.com.Dispatch.createInstanceNative(Native Method)
    at com.jacob.com.Dispatch.<init>(Dispatch.java:99)

I have gone through many of the SO posts but none of them have helped me so far

can anyone please guide me to the solution?

like image 558
sanbhat Avatar asked Mar 22 '26 13:03

sanbhat


1 Answers

A similar problem for me was solved by changing the jdk from a 64-bit to 32-bit.

like image 62
Aravind Sarma Yeluripati Avatar answered Mar 25 '26 01:03

Aravind Sarma Yeluripati