web stats
Mirth Community - View Single Post - RTF to PDF
Thread: RTF to PDF
View Single Post
  #6  
Old 05-27-2012, 02:36 PM
AlexToft AlexToft is offline
OBX.3 Kenobi
 
Join Date: Sep 2010
Location: Leeds, UK
Posts: 160
AlexToft is on a distinguished road
Default

You invoke OpenOffice like this (This is a Linux example as I don't work with Windows, but easy to adapt):

/path/to/openoffice/program/soffice.bin -headless -nofirststartwizard -accept="socket,host=localhost,port=8100;urp;StarOf fice.Service"

This is the command for the Python lib version of JobConverter:
java.lang.Runtime.getRuntime().exec("/usr/bin/python /opt/scripts/DocumentConverter.py /opt/input/”+source+”.rtf”+” /opt/output/”+destination+”.pdf”;

I then had another channel pick up the PDFs and send them to destination. Been about a year since I touched this, but will try and dig out the channel code for the Java version.
Reply With Quote