Try this:
If ActiveWorkbook.ProtectStructure = True Or ActiveWorkbook.ProtectWindows = True Then MsgBox "It's already protected." Else MsgBox "It's not protected." End If
Try this:
If ActiveWorkbook.ProtectStructure = True Or ActiveWorkbook.ProtectWindows = True Then MsgBox "It's already protected." Else MsgBox "It's not protected." End If