import codecs import pandas as pd xd = pd.ExcelFile('XXX.xls') pd.set_option('display.max_colwidth',1000)#设置列的宽度,以防止出现省略号 df = xd.parse() with codecs.open('XX.html','w') as html_file: html_file.write(df.to_html(header = True,index = False))
python 将Excel格式转换成HTML格式
猜你喜欢
转载自www.cnblogs.com/yaoliping/p/10019191.html
今日推荐
周排行