DxRichEdit.ReadOnly Property

Specifies whether users can edit a document.

Namespace: DevExpress.Blazor.RichEdit

Assembly: DevExpress.Blazor.RichEdit.v21.1.dll

Declaration

[Parameter]
public bool ReadOnly { get; set; }

Property Value

Type Description
Boolean

true if a user cannot change a document’s content; otherwise, false.

Remarks

Set the ReadOnly property to true to block keyboard input and disable UI elements and hotkeys that change document content. You can use the Rich Text Editor’s API to edit and format a document in read-only mode.

The ReadOnlyChanged event occurs when the ReadOnly property value changes.

The example below demonstrates how to enable read-only mode:

<DxRichEdit Id="myRich" @ref="richEdit" @bind-ReadOnly="@readOnly" />
@code {
    DxRichEdit richEdit { get; set; }
    bool readOnly { get; set; }
@* ... *@
        readOnly = true;
}
See Also