A newer version of this page is available. Switch to the current version.

RichEditControl Class

Represents a RichEdit control which is a container for the rich-text document providing all the necessary functionality.

Namespace: DevExpress.XtraRichEdit

Assembly: DevExpress.XtraRichEdit.v19.1.dll

Declaration

[ComVisible(false)]
[ToolboxBitmap(typeof(RichEditControl), "Bitmaps256.RichTextControl.bmp")]
[Docking(DockingBehavior.Ask)]
public class RichEditControl :
    Control,
    IPrintable,
    IBasePrintable,
    ISupportLookAndFeel,
    IToolTipControlClient,
    IGestureClient,
    IRectangularObjectRotationControllerOwner,
    IMouseWheelSupport,
    IInputStateProvider,
    IBarControllerOwner,
    IXtraTextEditor,
    IRichEditDocumentServer,
    IBatchUpdateable,
    IServiceContainer,
    IServiceProvider,
    IDisposable,
    IRichEditControl,
    IWin32Window,
    ICommandAwareControl<RichEditCommandId>,
    IInnerRichEditControlOwner,
    IInnerRichEditDocumentServerOwner,
    INotifyPropertyChanged,
    IRichEditDocumentLayoutProvider
<ComVisible(False)>
<ToolboxBitmap(GetType(RichEditControl), "Bitmaps256.RichTextControl.bmp")>
<Docking(DockingBehavior.Ask)>
Public Class RichEditControl
    Inherits Control
    Implements IPrintable,
               IBasePrintable,
               ISupportLookAndFeel,
               IToolTipControlClient,
               IGestureClient,
               IRectangularObjectRotationControllerOwner,
               IMouseWheelSupport,
               IInputStateProvider,
               IBarControllerOwner,
               IXtraTextEditor,
               IRichEditDocumentServer,
               IBatchUpdateable,
               IServiceContainer,
               IServiceProvider,
               IDisposable,
               IRichEditControl,
               IWin32Window,
               ICommandAwareControl(Of RichEditCommandId),
               IInnerRichEditControlOwner,
               IInnerRichEditDocumentServerOwner,
               INotifyPropertyChanged,
               IRichEditDocumentLayoutProvider

Related API Members

The following members accept/return RichEditControl objects:

Remarks

The RichEditControl is a word processing viewer. It processes text with any text direction.

image

The Document and the SubDocument interfaces are the entry points for a RichEdit document. Use the IRichEditControl.Document property to access the Document instance.

Refer to the Document Elements section for more information about the available elements and how to manage them.

You can load a document in code using the RichEditControl.LoadDocument() method overloads.

Check the Examples section for code examples used to solve different word processing tasks.

The RichEditControl provides control-specific options. Use the RichEditControlOptionsBase.Behavior property to retrieve settings used to control editor operations (save, print,clipboard operations, etc.)

The RichEditControlOptionsBase.DocumentCapabilities property provides access to options used to control the use of document elements.

The Visual Elements section describes the RichEditControl's interface and built-in dialogs.

The code sample below creates a new Rich Text Editor with a ribbon UI and loads a document to it. Refer to the Getting Started section for step-by-step tutorials on how to create a Rich Text Editor application and provide it with a command UI.

this.Controls.Add(richEditControl.CreateRibbon());
richEditControl.LoadDocument("Documents//FirstLook.docx");
See Also