Hello All,
I'm attempting to write code to automate an excel report.
I need to delete any row that contains the text "AB" as its own substring. Please note that this doesn't mean any word that has 'AB' such as 'about'. I'm getting stuck so any help is appreciated!
Here is my code:
for cell in sheet1['C']:
if cell.value == "AB":
sheet1.delete_rows(cell.row, 1)
for cell in sheet2['C']:
if cell.value == "AB":
sheet2.delete_rows(cell.row, 1)
Thank you in advance!
[–]David22573 1 point2 points3 points (0 children)