View Single Post
  #2   Report Post  
Posted to microsoft.public.excel.programming
JLGWhiz JLGWhiz is offline
external usenet poster
 
Posts: 3,986
Default Cannot remove password from file

You can't just blank out the password from the code and make it go away. You
have to unprotect the worksheet or workbook.

ThisWorkbook.Unprotect "password"

or

ActiveSheet.Unprotect "password"

Then save the file, close and re-open. It should not ask for the password.

"Steven" wrote:

I have a file that has a password. I enter the file and then SaveAs.. and
blank out the password and save the file. When I reopen the file it still
asks me for the password. Why is this?

Thank you,

Steven