invoke Impress via ant (or shell) to create .pdf

Java, C++, C#, Delphi... - Using the UNO bridges
Post Reply
brutzman
Posts: 5
Joined: Sat Feb 16, 2008 2:38 am
Location: Monterey California USA

invoke Impress via ant (or shell) to create .pdf

Post by brutzman »

i have a bunch of .odp presentations that occasionally get collected into a .zip archive.

would like to automate the production of .pdf versions

wondering, how can i invoke Impress using an ant build.xml script to create .pdf ?

alternatively, how can i invoke Impress to create .pdf via command line?
hol.sten
Volunteer
Posts: 495
Joined: Mon Oct 08, 2007 1:31 am
Location: Hamburg, Germany

Re: invoke Impress via ant (or shell) to create .pdf

Post by hol.sten »

brutzman wrote:alternatively, how can i invoke Impress to create .pdf via command line?
Try this for example: http://www.oooforum.org/forum/viewtopic.phtml?t=3772
Although the title suggests, that the macro covers only converting WORD to PDF, you can easily alter that to ANY of OOo's file formats to PDF. The only line you must change is the line setting the "FilterName" for storing the PDF. In the linked thread it looks like this:

Code: Select all

MakePropertyValue( "FilterName", "writer_pdf_Export" ),_ 
This is the PDF export filter for OOo's text documents.

To export an Impress file format change that line to:

Code: Select all

MakePropertyValue( "FilterName", "impress_pdf_Export" ),_ 
You'll find more available PDF export filters in this list: http://wiki.services.openoffice.org/wik ... st_OOo_2_1
OOo 3.2.0 on Ubuntu 10.04 • OOo 3.2.1 on Windows 7 64-bit and MS Windows XP
Post Reply