- xls2xlsx version: 0.2.0
- Python version: 3.12.3
- Operating System: Ubuntu 24.04 6.8.0-51-generic
Description
Technically this is not a bug report but maybe a feature that could be useful to others as well
I have an .XLS which has some parts protected (Marcos mostly) with an unknown password. The sheet can open without using a password in both Excel and LibreOffice. When trying to convert this file to .XLSX I get the error message:
"Exception converting FHLMC.XLS: Workbook is encrypted: skipping!"
I get a similar message when not testing from CLI.
The only thing I am needing is to read the cell data as it exists natively and extract the required data into a DataFrame for further processing down the line.
What I Did
I have also tried various other libraries like pyexcel and openpyxl but get a similar message about encryption.
I am able to get around this issue manually by opening the file in LibreOffice Calc and saving the file as an XLSX format. Evidently, LibreOffice will not convert Macros or save the protected areas of the original sheet when doing this operation.
I can provide an example file if desired but, it carries a confidentiality banner, so I can email or DM the file for testing, but I cannot post it publicly.
(venv) :~/Documents/Python$ xls2xlsx -v FHLMC.XLS
Exception converting FHLMC.XLS: Workbook is encrypted: skipping!
Description
Technically this is not a bug report but maybe a feature that could be useful to others as well
I have an .XLS which has some parts protected (Marcos mostly) with an unknown password. The sheet can open without using a password in both Excel and LibreOffice. When trying to convert this file to .XLSX I get the error message:
"Exception converting FHLMC.XLS: Workbook is encrypted: skipping!"
I get a similar message when not testing from CLI.
The only thing I am needing is to read the cell data as it exists natively and extract the required data into a DataFrame for further processing down the line.
What I Did
I have also tried various other libraries like pyexcel and openpyxl but get a similar message about encryption.
I am able to get around this issue manually by opening the file in LibreOffice Calc and saving the file as an XLSX format. Evidently, LibreOffice will not convert Macros or save the protected areas of the original sheet when doing this operation.
I can provide an example file if desired but, it carries a confidentiality banner, so I can email or DM the file for testing, but I cannot post it publicly.