Oharra
Orrialde honetara sartzeak baimena behar du. Saioa hasteko edo direktorioak aldatzen saia zaitezke.
Orrialde honetara sartzeak baimena behar du. Direktorioak aldatzen saia zaitezke.
Devuelve el tipo de protección para el documento especificado. Puede ser una de las siguientes constantes WdProtectionType: wdAllowOnlyComments, wdAllowOnlyFormFields, wdAllowOnlyReading, wdAllowOnlyRevisions o wdNoProtection.
Sintaxis
expresión. ProtectionType
expresión Variable que representa un objeto Document .
Ejemplo
Si el documento activo no está ya protegido, en este ejemplo se protege el documento para poder incluir sólo comentarios.
If ActiveDocument.ProtectionType = wdNoProtection Then
ActiveDocument.Protect Type:=wdAllowOnlyComments
End If
En este ejemplo, se deja sin protección el documento activo si estaba protegido.
Set Doc = ActiveDocument
If Doc.ProtectionType <> wdNoProtection Then Doc.Unprotect
Vea también
Soporte técnico y comentarios
¿Tiene preguntas o comentarios sobre VBA para Office o esta documentación? Vea Soporte técnico y comentarios sobre VBA para Office para obtener ayuda sobre las formas en las que puede recibir soporte técnico y enviar comentarios.