Create a word file (.doc) with python

I need to create a 2003 compatible doc file with python without using an external program like OpenOffice or an embedded language like java using Jasper, but I have not found a way to do this. Creating a docx is pretty simple and doesn't have a problem, but the doc file is another story. As an alternative solution, I tried to create an rtf file, but the Unicode incompatibility (there is a library there, solving this), and the lack of functions does not allow me to go further and satisfy my needs. Any tips or solutions? Thanks in advance!

+3
source share
3 answers

Since it has a binary format, you have few options. JODReports or Docmosis can sit back. OpenOffice allows you to create real doc files. You should be able to run either with Python, or perhaps on a bridge in Java, if that improves your performance.

+1
source

Google for python generate word documentleads to many good results. It seems that py docx or win32com.client are useful libraries.

To read docx files from Word 2003 you need to install a plugin .

+4
source

HTML-, pandoc, ODT. , PyUNO, Doc. , . http://wiki.services.openoffice.org/wiki/Python.

The specification of the .doc files, in my opinion, is rather messy and will not easily generate it directly using python. Despite some attempts by python libs to write doc files, they are at a very early stage and may not serve you ...

0
source

All Articles