FormProtection class

Office 2013 and later

Defines the FormProtection Class. When the object is serialized out as xml, its qualified name is w:formProt.

Namespace:  DocumentFormat.OpenXml.Wordprocessing
Assembly:  DocumentFormat.OpenXml (in DocumentFormat.OpenXml.dll)

public class FormProtection : OnOffType

[ISO/IEC 29500-1 1st Edition]

formProt (Only Allow Editing of Form Fields)

This element specifies that the contents of the current section shall be protected such that they cannot be edited by a user (if the consumer is displaying the document and allowing the user to make modification) except for the text contained in any form field or embedded control that is part of the current section.

[Example: Consider a section consisting of three paragraphs of text and a single text form field, located at the beginning of the second paragraph. If this section is protected in this manner, a user would only be permitted to edit the contents of the text form field, and all other contents would be locked to prevent user edits. end example]

The enforcement of this property is determined by the documentProtection element (§17.15.1.29), as it is possible to specify protection without turning it on.

Parent Elements

sectPr (§17.6.17); sectPr (§17.6.18); sectPr (§17.6.19)

This element’s content model is defined by the common boolean property definition in §17.17.4.

© ISO/IEC29500: 2008.

Any public static (Shared in Visual Basic) members of this type are thread safe. Any instance members are not guaranteed to be thread safe.
Show: