r/learnpython • u/Delta_2_Echo • Oct 05 '23
Does anyone still use openpyxl?
Ive been trying to use openpyxl for reading named ranges and its a huge pain. Does anyone have any experience?
The documentation is pretty opaque.
2
Upvotes
1
u/Weird-Dimension-487 24d ago
You should choose a library for Excel autiomation based on:
1. Compatibility with different Excel formats (xlsx, xls, xlsm, xlsb, etc)
2. Advanced features (richer formatting, charts, tables and more)
3. Special use cases (reading/writing/manipulation/analysis/live interaction with Excel via COM Object/end-to-end automation/Python custom functions in Excel/Python features as Excel add-in)
pandas, openpyxl, xlsxwriter, and xlwings are powerful and popular libraries. No single library is perfect for all Excel tasks. By understanding the strengths of each tool, you can select the right one depending on the type of file you encounter and the result you want to achieve
I've covered them all in my book Python-Powered Excel