Quantcast
Channel: Active questions tagged strikethrough - Stack Overflow
Viewing all articles
Browse latest Browse all 88

Openpyxl: Determining which character in a cell value is strikethrough

$
0
0

I'll first mention that I'm using Python 2.7 and Openpyxl 2.4.1

Essentially I have a sheet in a workbook that I'm cleaning. I'm going through each cell and checking if there is Strikethrough text. Assume I'm looking in Column A:

for i in range(1, sheet.max_row+1):    my_cell = sheet['A'+str(i)]    if my_cell.font.strikethrough == True:        #here's the tricky part

I know that it is possible to determine whether or not a cell contains strikethrough characters, but I would like to find which characters in the cell.value are strikethrough characters. I've read the docs and couldn't find too much on this. Is this possible with openpyxl?


Viewing all articles
Browse latest Browse all 88

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>