diff --git a/src/main.py b/src/main.py index 1d1fda9..1214fbe 100644 --- a/src/main.py +++ b/src/main.py @@ -73,7 +73,8 @@ def copy_excel_file(source_path, destination_path, passwords): source_sheet = source_wb[sheet_name] # Create new sheet in destination workbook - if source_sheet.sheet_type == 'chartsheet': + from openpyxl.chartsheet import Chartsheet + if isinstance(source_sheet, Chartsheet): # For chartsheets, we need to create a worksheet instead dest_sheet = dest_wb.create_sheet(title=sheet_name)