pythonexceltextopenpyxlfreeform

What solutions exist for including free format rich text data within an Excel file


What solutions exist (and what are the pros/cons) for including free-format, rich text data in an Excel file (along side the normal tabular data)?

This is the kind of data I'd like to include (in a separate worksheet): example of non-tabular data

Note that we're currently using openpyxl to generate Excel files from Python. We can use something other than Python/OpenPyXL if necessary, but keeping with Excel is a must (the accountants who use these reports won't use anything else).


Solution

  • The Excel specification makes it pretty tricky to do what you want. Currently, the smallest unit that you can apply styles to in openpyxl is a cell. As long as you can work with that restriction, you should be okay. Outlining is also supported.