I have a password protected Excel (.xlsx) file that I want to open using Python. I tried below package and code to open it:
xlwb = xlApp.Workbooks.Open("filename.xlsx", False, True, None, "Password")
but it throws me below error:
com_error: (-2147352567, 'Exception occurred.', (0, 'Microsoft Excel', "Sorry, we couldn't find filename.xlsx. Is it possible it was moved, renamed or deleted?", 'xlmain11.chm', 0, -2146827284), None)
Although the file is located in that directory. Could anyone help regarding how to open the password protected Excel file using Python?