解除工作表密码保护(方便用的时候查看)
作者:互联网
1、查看代码
步骤:右键【sheet1】-【查看代码】-打开代码窗口。
2、插入代码
代码:Sub DeletePW()
ActiveSheet.Protect DrawingObjects:=True, Contents:=True, AllowFiltering:=True
ActiveSheet.Protect DrawingObjects:=False, Contents:=True, AllowFiltering:=True
ActiveSheet.Protect DrawingObjects:=True, Contents:=True, AllowFiltering:=True
ActiveSheet.Protect DrawingObjects:=False, Contents:=True, AllowFiltering:=True
ActiveSheet.Unprotect
End Sub
步骤:粘贴代码,点击【运行】即可。
标签:DrawingObjects,AllowFiltering,Protect,查看,密码保护,ActiveSheet,解除,True,Contents 来源: https://blog.csdn.net/dylgs314118/article/details/100540177