OpenOffice3.0以服务方式运行在Windows平台(文件转换服务器解决方案)
2009-10-19 15:04
561 查看
1.准备以下软件
OpenOffice3.0,Windows Resource Kit Tools 分别默认安装
2.打开Windows Resource Kit Tools -> Command Shell
执行以下命令
Cmd代码
"C:\Program Files\Windows Resource Kits\Tools\instsrv" OpenOfficeUnoServer "C:\Program Files\Windows Resource Kits\Tools\srvany.exe"
打开 管理工具->服务 可以找到以 OpenOfficeUnoServer 命名的服务
3.打开注册表寻找以下路径
HKEY_LOCAL_MACHINE -> SYSTEM ->ControlSet001 ->Services ->OpenOfficeUnoServer
新建项 Parameters
在该项下添加两个字符串值
key:Application
value:C:\Program Files\OpenOffice.org 3\program\soffice.exe
key:AppParameters
value:-invisible -headless -accept=socket,host=127.0.0.1,port=8100;urp; -nofirststartwizard
4.在服务控制台,启动 openoffice 服务
5.在CMD中用以下命令查看8100是否已被监听
Cmd代码
netstat -anop tcp
这样OpenOffice3.0就以服务方式运行在Windows系统上了。(使用cmd命令:netstat -anp tcp查看8100端口是否工作)
然後可以通过socket方式连接openOffice,以使用openoffice提供的某些服务,如文件转换服务,ms office转pdf等等。
开源项目 JODConverter 就是结合openoffice来进行文档转换的java组件。
另外有一個命令行工具swftools,該工具可以將pdf轉換為swf格式的文檔,提供給ie客戶端流覽。
這裏有一篇文章可以參考配置JODConverter为一个WEB应用
备注:
安装配置可以用bat文件来快速实现,运行前请先修改相应目录参数
代码
OpenOffice3.0,Windows Resource Kit Tools 分别默认安装
2.打开Windows Resource Kit Tools -> Command Shell
执行以下命令
Cmd代码
"C:\Program Files\Windows Resource Kits\Tools\instsrv" OpenOfficeUnoServer "C:\Program Files\Windows Resource Kits\Tools\srvany.exe"
打开 管理工具->服务 可以找到以 OpenOfficeUnoServer 命名的服务
3.打开注册表寻找以下路径
HKEY_LOCAL_MACHINE -> SYSTEM ->ControlSet001 ->Services ->OpenOfficeUnoServer
新建项 Parameters
在该项下添加两个字符串值
key:Application
value:C:\Program Files\OpenOffice.org 3\program\soffice.exe
key:AppParameters
value:-invisible -headless -accept=socket,host=127.0.0.1,port=8100;urp; -nofirststartwizard
4.在服务控制台,启动 openoffice 服务
5.在CMD中用以下命令查看8100是否已被监听
Cmd代码
netstat -anop tcp
这样OpenOffice3.0就以服务方式运行在Windows系统上了。(使用cmd命令:netstat -anp tcp查看8100端口是否工作)
然後可以通过socket方式连接openOffice,以使用openoffice提供的某些服务,如文件转换服务,ms office转pdf等等。
开源项目 JODConverter 就是结合openoffice来进行文档转换的java组件。
另外有一個命令行工具swftools,該工具可以將pdf轉換為swf格式的文檔,提供給ie客戶端流覽。
這裏有一篇文章可以參考配置JODConverter为一个WEB应用
备注:
安装配置可以用bat文件来快速实现,运行前请先修改相应目录参数
代码
"C:\Program Files\Windows Resource Kits\Tools\instsrv" OpenOfficeUnoServer "C:\Program Files\Windows Resource Kits\Tools\srvany.exe" reg add HKEY_LOCAL_MACHINE\SYSTEM\ControlSet001\services\OpenOfficeUnoServer\Parameters /ve /d reg add HKEY_LOCAL_MACHINE\SYSTEM\ControlSet001\services\OpenOfficeUnoServer\Parameters /v Application /t REG_SZ /d "C:\Program Files\OpenOffice.org 3\program\soffice.exe" reg add HKEY_LOCAL_MACHINE\SYSTEM\ControlSet001\services\OpenOfficeUnoServer\Parameters /v AppParameters /t REG_SZ /d "-invisible -headless -accept=socket,host=127.0.0.1,port=8100;urp; -nofirststartwizard"
相关文章推荐
- memcached ,redis 在windows下以服务方式运行
- nginx for windows: 让nginx以服务的方式运行
- 以Windows服务方式运行ASP.NET Core程序
- (转)在Windows上以服务方式运行 MSOPenTech/Redis
- MongoDB 3.4 安装以 Windows 服务方式运行的详细步骤
- install redis service as windows service in windows platform--在windows平台下以windows服务方式安装redis
- Windows下Nginx以服务的方式运行
- 以服务方式运行Apache for Windows
- 【转载】nginx for windows: 让nginx以服务的方式运行
- 在Windows上以服务方式运行 Redis
- 在Windows上以服务方式运行 MSOPenTech/Redis
- nginx for windows: 让nginx以服务的方式运行(亲侧修正)
- 以服务方式运行Apache for Windows
- 使用Apache Commons Daemon 来实现Jetty7 以Windows 服务方式运行
- Windows Service开发日志四(用程序设置服务的运行状态及启动方式)
- 在Windows上以服务方式运行 MSOPenTech/Redis
- Redis启动多个实例,并以windows服务方式运行
- 在Windows上以服务方式运行 MSOPenTech/Redis
- coTurn 运行在Windows平台的方法及服务与客户端运行交互流程和原理
- 以 Console 方式运行、调试、编译 .Net 编写的 Windows 服务