Display Excel file in website with edit functionality

Hi Guys,

I’m fairly new to Django and here’s a uphill task i’ve been given to with a deadline and i have no seniors to guide me, hence i’m yielding for your support here.

Basically i have an excel file with some calculated field that i have to show it in website using Django that lets users edit certain columns and other columns depending on it should get recalculated and retrieved in website

I used the following approach:

  1. Loaded the excel file to pandas df
  2. converted df into json file and passed that into HTML
  3. In HTML file, using a for loop i’m traversing and displaying the data, this works well but the problem is with adding a functionality for user to edit certain columns and recalculations.

Please guide me or help me with the approach or if you can point me to any documents, i’ll be very much thankful to you.

This really isn’t a Django issue. What you’re looking for is some type of JavaScript library to do this. Django can serve the page and accept the changes, but all the work from a UI perspective is done within the browser.

You might be looking for something like the Google XLS Editor.

Or, if you’re requirement is just to provide the ability to enter / edit data in a grid-style format, but not necessarily specifically an Excel spreadsheet, you might find the Datatables Editor to be the right solution.

I found a bunch of options at JSpreadsheets.