I have a workbook name m.xlsx, but it's password protected and I've forgotten the password. How can I open it or un-protect it?
The following code does not work:
- Unprotect workbook without password
- I need the command to unprotect an Excel file from python
It ask for password when opened, and the above code does not unlock the workbook.
So, I want to put this code in a new workbook and then link my excel file with a code in place of THISWORKBOOK. Is there a way to put the m.xlsx file path without opening it (as opening of file needs password), and then run this code to unprotect the m.xlsx file?
Or is there any better way to unprotect workbook in VBA or Python programming? I have checked some Python code but they are opening the file and that is where the problem is.