Questions tagged [odfpy]
19 questions
0
votes
0 answers
AttributeError: 'str' object has no attribute 'P' when trying to extract text from all .odt files, recursively, using odfpy library
I wrote a script in order to convert all my .odt files, recursively - that is in the CWD and all the subdirectories, to text files. The code in question:
import glob, os
from odf import text, teletype
from odf.opendocument import load
fileList =…

John Smith
- 835
- 1
- 7
- 19
-1
votes
1 answer
How to set cell formula using odfpy
I keep getting Err:508 or #Name? (Err:525) when opening a spreadsheet created with odfpy and putting a formula in a cell with the following code:
tc = TableCell( valuetype="string", formula=calc, value=0 )
In the spreadsheet, the formula looks…

Victoria
- 497
- 2
- 10
- 20
-1
votes
1 answer
OpenOffice odt document, regex, and arrays
I am trying to work with a ~300 page odt document. I know how to load documents in python, and least in a basic way. That didn't work for odt (it isn't a txt file). I researched this and installed the odfpy library, although it doesn't seem…

Iain Curtis-Shanley
- 21
- 3
-1
votes
1 answer
How to use bold text inside a spreadsheet using odfpy?
I'm writing a spreadsheet (ods) using odfpy but I can't figure out how to make it use bold text for a cell.

Joril
- 19,961
- 13
- 71
- 88