V2EX = way to explore
V2EX 是一个关于分享和探索的地方
现在注册
已注册用户请  登录
推荐学习书目
Learn Python the Hard Way
Python Sites
PyPI - Python Package Index
http://diveintopython.org/toc/index.html
Pocoo
值得关注的项目
PyPy
Celery
Jinja2
Read the Docs
gevent
pyenv
virtualenv
Stackless Python
Beautiful Soup
结巴中文分词
Green Unicorn
Sentry
Shovel
Pyflakes
pytest
Python 编程
pep8 Checker
Styles
PEP 8
Google Python Style Guide
Code Style from The Hitchhiker's Guide
pidan
V2EX  ›  Python

求助:用 openpyxl 修改页脚 &[ 不显示

  •  
  •   pidan · 2020-03-31 01:14:47 +08:00 · 1593 次点击
    这是一个创建于 1489 天前的主题,其中的信息可能已经有所发展或是发生改变。

    用的 ms office excel2019

    from openpyxl import Workbook, load_workbook
    wb = load_workbook('D:/Code/python/200330-SH3-A3-02R30.xlsx')
    ws = wb.active
    ws.oddFooter.right.text = "2020/03/31  &[时间]"
    wb.save("D:/Code/python/new200330-SH3-A3-02R30.xlsx")
    

    设置好后 &[ 不会直接显示,只会显示 时间] ,然后点自定义页脚,显示里边的内容没问题,然后点确定就正常了 alt 图片

    目前尚无回复
    关于   ·   帮助文档   ·   博客   ·   API   ·   FAQ   ·   我们的愿景   ·   实用小工具   ·   3111 人在线   最高记录 6543   ·     Select Language
    创意工作者们的社区
    World is powered by solitude
    VERSION: 3.9.8.5 · 31ms · UTC 13:49 · PVG 21:49 · LAX 06:49 · JFK 09:49
    Developed with CodeLauncher
    ♥ Do have faith in what you're doing.