Proteger ou desproteger todas as folhas de um Livro - JJoão (02/2001)
Macro que inverte o estado de protecção de todas as folhas de um livro, desde que estas não estejam protegidas com passsword.
Sub Proteger_Desproteger()
For Each wSheet In ActiveWorkbook.Sheets
With wSheet
If .ProtectContents = False Then
.Protect DrawingObjects:=True, _
Contents:=True, _
Scenarios:=True
Else
.Unprotect
End If
End With
Next
End Sub
|