【问题标题】:Python's excel2img package not working with MS office 2016Python 的 excel2img 包不适用于 MS Office 2016
【发布时间】:2021-03-19 05:22:20
【问题描述】:

使用excel2img包获取excel截图。

最近从 2013 年将 MS office 版本升级到 2016 年。

Pyhton 的包“excel2img”与 MSoffice 2013 一起使用,但观察到 MS Office 版本 2016 的上述错误,不确定问题。请指导。谢谢!

导入excel2img

excel2img.export_img("test.xlsx", "status.png", "Sheet1", None)

文件“C:\Python37\lib\site-packages\excel2img\excel2img.py”,第 113 行,在 export_img 对于 rng.parent.Shapes 中的形状:通过 getattr 中的文件“C:\Python37\lib\site-packages\win32com\client__init__.py”,第 473 行 raise AttributeError("'%s' 对象没有属性 '%s'" % (repr(self), attr)) AttributeError: '' 对象没有属性 'parent'

【问题讨论】:

    标签: python ms-office


    【解决方案1】:

    @May0021 即使我在搜索相同的内容,但根据以下数据,excel2img 似乎不支持 2016。 Excel2img requirement

    【讨论】:

      猜你喜欢
      • 2022-07-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 2021-06-01
      • 2020-11-06
      • 2016-06-27
      相关资源
      最近更新 更多