如何取消保护Excel工作簿 [英] How to unprotect an Excel workbook
本文介绍了如何取消保护Excel工作簿的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
具体来说,我想这样做VBA,因为最终我想能够使用循环对多个文件执行此操作。我尝试使用:
ThisWorkbook.Unprotect(Password =[password])
但这绝对没有。
解决方案
如果是打开文件的密码,您需要:
Thisworkbook.Password =
然后保存。
Wb.Unprotect
将删除保护工作簿结构/窗口的密码。
I have an Excel workbook that is password protected (the entire document, not just a sheet or set of sheets - you can't open the file without the password). I know the password, so I am able to open it, but there is no obvious way to turn off the password protection.
Specifically, I would like to do this in VBA, because eventually I want to be able to do this to multiple files using a loop. I tried using:
ThisWorkbook.Unprotect(Password = "[password]")
but this does absolutely nothing.
解决方案
If it's the password to open the file, you want:
Thisworkbook.Password = ""
then save it.
Wb.Unprotect
would remove the password that protects the workbook structure/windows.
这篇关于如何取消保护Excel工作簿的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文