Recently, I had to create a new web app, which would generate PDF reports based on data stored in excel worksheets. As usual, I used Django along with many other Python libraries for this.
It has following parts:
- HTML Form - To select excel files and upload it to server
- Parsing uploaded excel file - Basic validation followed by reading data from worksheets. I used
xlrdmodule from Python-Excel project for this.
- Data analysis and plots - I used
pandas, Python Data Analysis Library, and
matplotlib, a python 2D plotting library, for this.
- PDF Generation -
RMLfrom ReportLab along with awesomeness of Django Templates seems suitable for this job. I used
z3c.rml, an open source implementation of
RMLstandard by Zope Foundation.
So, everything was working like a charm, except the fact that web app was reading data from first worksheet by index whenever an excel workbook was uploaded. But, user should be able to tell which worksheet to read from, right?Read more ...