赞
踩
安装包 pip install xlsx2html
xlsx 表格样式如
将excel 表格的内容转化成html ,并在页面中显示
直接上代码
# -*- coding: utf-8 -*-
# 将表格 转化成html
import re
import os
from xlsx2html import xlsx2html
def re_html(name,proname):
tb1_html = str(name).replace('.xlsx','c.html')
tb2_html = str(name).replace('.xlsx','m.html')
xlsx2html(filepath=name, sheet='Chemical Composition',output=tb1_html)
try:
Copyright © 2003-2013 www.wpsshop.cn 版权所有,并保留所有权利。