pyuno and PDF output

Sells, Fred fred at adventistcare.org
Thu May 4 13:20:57 EDT 2006


I can use java to output a PDF file using uno, but when I try to do it in
python, I get an IO Exception with no added information.   The relevant code
snippet follows:

from com.sun.star.beans import PropertyValue
PDF    = PropertyValue( "FilterName" , 0 , "writer_pdf_Export", 0 )
doc2.storeAsURL("file:///C:/alleclipse/OpenOffice/test2.pdf", (PDF,) )

if I don't specify any properties, it writes an "odt" file just fine, but
when I specify (PDF,) it breaks.





Traceback (most recent call last):
  File "oomerge.py", line 137, in ?
    test1()
  File "oomerge.py", line 74, in test1
    doc2.storeAsURL("file:///C:/alleclipse/OpenOffice/test2.pdf", (PDF,) )
__main__.com.sun.star.task.ErrorCodeIOException

---------------------------------------------------------------------------
The information contained in this message may be privileged and / or
confidential and protected from disclosure. If the reader of this message is
not the intended recipient, you are hereby notified that any dissemination,
distribution or copying of this communication is strictly prohibited. If you
have received this communication in error, please notify the sender
immediately by replying to this message and deleting the material from any
computer.
---------------------------------------------------------------------------



More information about the Python-list mailing list