0
我想使用openpyxl更改图表的背景颜色,as in this example。如何使用openpyxl设置图表的绘图区域的背景颜色
在谷歌小组讨论,我发现下面的代码片段:
from openpyxl.chart.shapes import GraphicalProperties
props = GraphicalProperties(solidFill="999999")
chart.graphical_properties = props
chart.plot_area.graphical_properties = props
但当保存到Excel文件,它并没有在图表上的任何影响。
非常感谢@Friedemann这工作! –
然后,我建议您将答案标记为已接受。 ;) –