How to unprotect the excel sheet if forgot the password

Copper Contributor

Hi team need support to unprotect my sheet which is password protected and forgot the password

 

295 Replies

@NikolinoDE  The code ran okay. I received the "Finished" message box, but the active sheet was still locked. I do not understand how the code can work when 10 characters cycle between A and B and only the last character cycles between all of the keyboard characters.

 

Thank you,

Andy

This worked for me: unzipping file, removing sheetProtection XML tags from the sheetN.xml files and zipping files again, as per Damo_S post.

 

Unfortunately, the VBA code approach completed but didn't succeed in unprotecting the sheet.

@Deleted Try this. Save the workbook as an Excel 97-2003 Workbook and then run the code. That worked for me.

 

Andy

@NikolinoDE 

Old thread: hoping someone sees this.  I have run this macro, but keep getting Compile Error, Syntax Erro on the following:  .Unprotect Chr(i) & Chr(j) & Chr(k) & Chr(l) & Chr(m) & _

 

I've got a workbook with multiple locked cells, and the person with the p/w lives on Sanibel Island... and I'm trying to finish our budget.   

Thanks!

david

@David_DSHill 

 

Put all that code on one line and remove the underscore.

 

Andy

@Andy_R_327 

 

Thanks, Andy.  Caught that right after I posted.   Ran, but no results - never got the Finished, message, though.   I also noticed the Protection uses SHA-512 and not AES-128, so perhaps not going to give an answer?  Weird part is task manager shows almost zero CPU usage.  Not sure what is going on.

 

thanks,

 

David

@David_DSHill 

 

Did you save the workbook as an Excel 97-2003 workbook before you ran the macro?

 

 

Andy

@Andy_R_327 

 

Hey Andy, 

 

Thanks.  Yes, I saved it as a xls (97-2003) file first.  That is why I am flummoxed.  It should at least push the Finished msg box or fail.  It just stays silent. 

thanks/David

@NikolinoDE 

I just came across this code today.  One additional question.  I have a password on the workbook and have a tab hidden.  I need to update the lists on that hidden tab for my data validation drop down lists.  I have opened the page with the data validation, but I cannot access the back-up list.  

 

Is there a version of this code that removes the password from the entire workbook?

 

Thank you in advance for your assistance.

 

Christina

Not that I know of. Try Google.

Andy

@NikolinoDE 

I have the same problem

I could not attach the file you can help me remove the password protection on the cells. I can email you the file. 

My email is email address removed for privacy reasons 

@NikolinoDE I just tried this on my iMac.  I thought it was going to work, but I got a syntax error message.  Do you know if the code would be different for the Mac OS?  Thank you!

I have no idea. I hate Macs!

@NikolinoDE It has done the miracle. Thanks

Sir you're information is golden and saved me as well as some of colleagues a great amount of time!
Glad I could help!

@NikolinoDE You are remarkable.  This worked for me.  Phew!  Only took a few seconds.  Thanks!

@NikolinoDE could you please help me with this? I don’t see what to the right was to be copied and pasted. I have an excel chart that’s about 3 years old I just found and needed some info off of it; but  I can’t remember the password for it.  any other tips would be appreciated! For full disclosure I’m not a developer or IT expert by any stretch of the imagination. 

@vedangbapna 

Funny loophole if you have a Mac. Open the file in Numbers which will strip the protection, then export back to Excel.

Very interesting! Thanks for the info!

Andy