简体   繁体   English

如何将Open Office(32位)与64位Java运行时环境集成?

[英]How can I integrate Open Office (32-bit) with a 64-bit Java Runtime Environment?

I am currently running a ColdFusion 11 64-bit installation with Java JRE 1.8.66 64-bit on Windows 2012. I want to install Open Office along with the JODConverter Java library so that I can use the libraries to convert Office files to PDFs with code. 我目前正在Windows 2012上运行带有Java JRE 1.8.66 64位的ColdFusion 11 64位安装。我想安装Open Office和JODConverter Java库,以便我可以使用这些库将Office文件转换为PDF码。 I have successfully run this installation in Windows 2003 32-bit with ColdFusion 8 32-bit. 我已经使用ColdFusion 8 32位在Windows 2003 32位中成功运行此安装。 I also have this successfully working in Windows 7 with ColdFusion 8 and 64-bit JRE. 我也使用ColdFusion 8和64位JRE在Windows 7中成功运行。

On the CF11/2012 server, I have installed Open Office 3.4.1, but it only allows a 32-bit installation. 在CF11 / 2012服务器上,我安装了Open Office 3.4.1,但它只允许32位安装。 I'm thinking the 32-bit/64-bit differences is causing a problem because every time I try to instantiate the Java library, it throws an "Object instantiation exception": 我认为32位/ 64位差异导致问题,因为每次我尝试实例化Java库时,它都会抛出“对象实例化异常”:

Stack trace: 堆栈跟踪:

Message: org.artofsolving.jodconverter.office.DefaultOfficeManagerConfiguration
    StackTrace: java.lang.ClassNotFoundException: org.artofsolving.jodconverter.office.DefaultOfficeManagerConfiguration
        at coldfusion.bootstrap.BootstrapClassLoader.loadClass(BootstrapClassLoader.java:235)
        at java.lang.ClassLoader.loadClass(Unknown Source)
        at coldfusion.runtime.java.JavaProxyFactory$1.run(JavaProxyFactory.java:156)
        at java.security.AccessController.doPrivileged(Native Method)
        at coldfusion.runtime.java.JavaProxyFactory.getProxy(JavaProxyFactory.java:151)
        at coldfusion.runtime.ProxyFactory.getProxy(ProxyFactory.java:65)
        at coldfusion.runtime.CFPage.createObjectProxy(CFPage.java:6167)
        at coldfusion.runtime.CFPage.CreateObject(CFPage.java:6130)
        at coldfusion.runtime.CFPage.CreateObject(CFPage.java:6064)
        at coldfusion.runtime.CFPage.CreateObject(CFPage.java:6039)
        at coldfusion.runtime.CFPage.CreateObject(CFPage.java:5986)

Is there any way to get this integration to work correctly? 有没有办法让这种集成正常工作?

似乎最好的解决方案是用CFDOCUMENT调用替换我现有的代码 - 它调用JODConverter java库 - 因为ColdFusion 11中不再需要Java对象来实现所需的功能。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM