简体   繁体   English

在 Python 中显示 Excel 工作表的最佳(最简单?)方法

[英]Best (easiest?) way to display an Excel sheet in Python

I've looked around on the web and haven't found a decisive answer to the question.我在网上环顾四周,没有找到这个问题的决定性答案。 I see that HTML.py is available, as well as win32com.client.我看到 HTML.py 和 win32com.client 可用。
I'm sure they have their pros/cons, so I guess my question is aptly said: Whats the accepted, common, no frills way to take an XL spreadsheet and output it as a webpage?我确定他们有他们的优点/缺点,所以我想我的问题很恰当地说:采用 XL 电子表格并将其输出为网页的公认的、常见的、简洁的方式是什么?

I'm using Django btw, if that makes any difference.顺便说一句,我正在使用 Django,如果这有什么不同的话。

EDIT: I should have been more explicit originally.编辑:我本来应该更明确的。 I've manipulated my xl file to my hearts content using xlrd to read the file, and then re-writing it with xlwt.我已经使用 xlrd 将我的 xl 文件处理为我的心内容来读取文件,然后用 xlwt 重写它。 So now I have a .xlsx file.所以现在我有一个 .xlsx 文件。
What I'm looking to do is output this whole and caboodle(xlsx file) in HTML.我想要做的是在 HTML 中输出整个和 caboodle(xlsx 文件)。 The grid, color formatting, the actual table itself.网格、颜色格式、实际表格本身。 NOT just the contents.不仅仅是内容。
Apologies for the lack of clarity.对不清楚的地方深表歉意。

xlrd是一个从 Excel 文件中提取数据的简单库。

通过一些例子学习 xlrd 的一个好的开始是这个站点

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

相关问题 在另一个 python 线程中执行 function (有响应)的最佳(最简单)方法? - Best (easiest) way to execute a function (with response) in another python thread? 在 Python 3.4 中,比较路径的最佳/最简单方法是什么? - In Python 3.4, what is best/easiest way to compare paths? 使用python / pandas在Excel上创建颜色渐变的最简单方法? - Easiest way to create a color gradient on excel using python/pandas? 通过python在Excel工作表中显示none单元格 - To display the none cell in the excel sheet by python Python:按名称获取 smartsheet Sheet 的最佳方法 - Python: Best way to get smartsheet Sheet by name 在Linux中从python显示pdf,ps或dvi文件的最简单方法 - Easiest way to display a pdf, ps or dvi file from python in linux Pygame:从精灵表中显示这些船只及其运动的最佳方式是什么? - Pygame: What is the best way to display these ships and their movement from sprite sheet? 打开现有 Excel 文件、清除现有工作表并将数据框写入该工作表的最佳方法 - Best way to open existing excel file, clear an existing sheet and write dataframe to that sheet Python:获取一个复选框 - 最简单的方法 - Python: get a checkbox - the easiest way 如何使用python在新的Excel工作表中显示大量数据 - how to display huge data in new excel sheet using python
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM