Openpyxl with Django

122 views
Skip to first unread message

Ernest Thuku

unread,
Jan 12, 2021, 9:23:11 AM1/12/21
to Django users
Hello, I need a way I can connect a python script that reads excel file using openpyxl and instead of interacting with the terminal/cmd I can interact it via a web app(in browser). Thank you.

Kasper Laudrup

unread,
Jan 12, 2021, 11:22:26 AM1/12/21
to django...@googlegroups.com
Hi Ernest,
The simplest would most likely be to call the script (or preferably, a
function in the script) from a view and then render a template with the
data returned from the function.

Of course, a lot of details are missing like where the Excel file comes
from and what you mean by "interact with it", but that should be a start
I hope.

Kind regards,

Kasper Laudrup

Ernest Thuku

unread,
Jan 12, 2021, 11:50:42 AM1/12/21
to Django users
Thank you so much..I want to upload it and then return the contents of the excel sheet to the templates and display it on the browser. 

--
You received this message because you are subscribed to the Google Groups "Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to django-users...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/django-users/2f8bde94-5889-623a-4b3e-83427d220c56%40stacktrace.dk.
Reply all
Reply to author
Forward
0 new messages