0

I'm trying to read the background color of a cell in a table in a pptx file with python-pptx module, but I am only able to set a _Cell's fill property, not able to read a value from it.

I tried reading fill.back_color, but they were all (255,255,255) after doing fill.patternize() as the output suggests. What am I doing wrong? Or should I use another package?

My pptx file was not made with python.

M. Zhang
  • 750
  • 8
  • 18

1 Answers1

0

As @scanny pointed out, fill.back_color is used for pattern fills. For the cell color, I should read from fill.fore_color.

M. Zhang
  • 750
  • 8
  • 18