Rich Text Editor

  • 3 minutes to read

The DevExpress ASP.NET client RichEdit control allows users to create, open, modify, print, save, and convert rich-formatted text files.

Rich Text Editor Overview

Frameworks

RichEdit is a client control that you can use in various client and server frameworks. The control has a common client implementation for all the supported frameworks.

Document Formats

The RichEdit control supports the following file extensions:

  • DOCX
  • RTF
  • TXT
  • PDF export (include programmatically)

You can use third-party server libraries (for instance, DevExpress Office File API) to convert a document to a suitable format.

Client API

The RichEdit class implements the control's client functionality and includes the following most commonly used properties:

  • document - provides access to information about a document model.
  • selection - provides access to the selected content, allows you to position the cursor within a document, and to select document content elements.

The following section contains a number of client code samples: Examples.

Server API

Use the RichEditBuilder class to create and customize the control on the server.

You can modify a document on the server side with the non-visual cross-platform .NET library Office File API.

Features

  • The RichEdit works completely on the client side.
  • Fast document editing.
  • Lightweight Deployment. You can separate source files from other controls and compile required libraries into a RichEdit bundle.
  • Ribbon UI. You can customize the Ribbon UI on the server and client sides. (See demo)
  • Document Management. The ribbon command buttons allow users to create, open, edit, print, and save rich-text documents of any size. You can customize the default ribbon UI and perform file operations in code. (More details | See demo)
  • Fields. You can insert special placeholder fields, which are replaced with data when the document is displayed or printed. (See demo)
  • Mail Merge. The Mail Merge retrieves data from a bound data source and fills in the fields of a document template. This feature can be used to compose, preview, and generate catalogs, reports, or personalized letters. (See demo)
  • Autocorrect. Analyze, modify, and substitute the typed text. (See demo)
  • Spell Check (client-side).
  • Simple View. In this mode, a document occupies all the available area inside the control. Users can enable/disable the Simple view mode using ribbon commands. (See demo)
  • Font Management. The Fonts method allows you to specify fonts available to the control. This information is required when you export a document to PDF on the client side (exportToPdf) or print a document in client PDF printing mode. (More details)
  • Document Protection. The RichEdit control allows users to open and view protected documents. You can identify users and enable text ranges permitted for the specified user or group. (More details | See demo)
  • Localization. You can localize the RichEdit control to a variety of languages and cultures. (More details)

Unsupported features are listed in the following topic: Unsupported Features

Demos and Examples

The DevExpress .NET Products Installer installs RichEdit control demos to your local machine.

  • Try demos in action: run the Demo Center 20.2 application from the Windows Start menu or run C:\Users\Public\Documents\DevExpress Demos 20.1\Components\Components\Bin\DevExpress.DemoCenter.v20.2.exe (by default).

  • Demo solution files: C:\Users\Public\Documents\DevExpress Demos 20.2\Components\ASP.NET\CS\AspNetCoreDemos.RichEdit.