现在的位置: 首页 > 综合 > 正文

Java操作Microsoft Word之jacob (1)

2013年07月11日 ⁄ 综合 ⁄ 共 760字 ⁄ 字号 评论关闭

  现在我们一起来看看,用Java如何操作Microsoft Word。

    jacob,官网是http://danadler.com/jacob 这是一个开源的工具。最新版本1.7

    官方的解释是:The JACOB Project: A JAva-COM Bridge

    这是官方对下载文件的说明:
    jacob.jar: a JAR file for the java classes which you must add to your CLASSPATH. The package names replace com.ms with com.jacob (for example com.ms.com.Variant maps to com.jacob.com.Variant.
    jacob.dll: a small Win32 DLL which you must add to your PATH.
    samples: provided in Java source and compiled form to demonstrate various features of the product. In particular, a set of wrapper classes for Microsoft? ADO are provided as samples.

    开发环境:
    JDK 1.6
    MyEclipse Enterprise Workbench Version: 7.0 Milestone-1
    Tomcat 5.5.27
    现在MyEclipse中新建一个项目jacob,将jacob的jar包放到该项目的类库中。
    我的jacob版本是1.14.3 。

 

 

 

    下面这一步非常重要,就是拷贝jacob目录中jacob-1.14.3-x86.dll文件到系统环境变量目录中
    一般情况就放在当前jdk中bin目录下。

 

 

抱歉!评论已关闭.