The DocumentPermissions class provides settings determining how the document can be edited, when the EditMode is changed from Edit to ReadAndSelect.


public class DocumentPermissions
Public Class DocumentPermissions

Introduced: X15.


The following example shows the DocumentPermissions class. Here, four properties are set to 'false', indicating a restricted document.

textControl1.EditMode = TXTextControl.EditMode.ReadAndSelect;

TXTextControl.DocumentPermissions documentPermissions = new TXTextControl.DocumentPermissions();
documentPermissions.AllowCopy = false;
documentPermissions.AllowFormatting  = false; 
documentPermissions.AllowFormattingStyles = false; 
documentPermissions.AllowPrinting =  false;
TextControl1.EditMode = TXTextControl.EditMode.ReadAndSelect

Dim documentPermissions As TXTextControl.DocumentPermissions = New TXTextControl.DocumentPermissions()
documentPermissions.AllowCopy = False
documentPermissions.AllowFormatting = False
documentPermissions.AllowFormattingStyles = False
documentPermissions.AllowPrinting = False


Property Description
AllowCopy Specifies whether document content can be copied to the clipboard.
AllowEditingFormFields Specifies whether form fields can be edited.
AllowFormatting Gets or sets a value specifying whether the document can be formatted.
AllowFormattingStyles Gets or sets a value specifying whether formatting styles can be used to format the document.
AllowPrinting Gets or sets a value specifying whether the document can be printed.
ReadOnly Gets or sets a value specifying whether the document is read only.