Skip to main content
A newer version of this page is available. .

HtmlEditorHtmlEditingSettings.ProcessRtfContentPastingOnServer Property

Gets or sets a value that specifies whether to process the copied/cut RTF content on the server side.

Namespace: DevExpress.Web.ASPxHtmlEditor

Assembly: DevExpress.Web.ASPxHtmlEditor.v19.2.dll

Declaration

[DefaultValue(true)]
public bool ProcessRtfContentPastingOnServer { get; set; }

Property Value

Type Default Description
Boolean **true**

true, to process the copied/cut RTF content on the server side; otherwise, false.

Property Paths

You can access this nested property as listed below:

Object Type Path to ProcessRtfContentPastingOnServer
ASPxHtmlEditor
.SettingsHtmlEditing.ProcessRtfContentPastingOnServer
HtmlEditorBinderSettings
.HtmlEditingSettings.ProcessRtfContentPastingOnServer
HtmlEditorSettings
.SettingsHtmlEditing.ProcessRtfContentPastingOnServer
MVCxHtmlEditor
.SettingsHtmlEditing.ProcessRtfContentPastingOnServer

Remarks

To paste the RTF content from a clipboard with the original formatting, set the ProcessRtfContentPastingOnServer property to true. It enables converting the RTF content to HTML on the server and then paste it to the editor.

<dx:ASPxHtmlEditor runat="server">
    <SettingsHtmlEditing ProcessRtfContentPastingOnServer="true"></SettingsHtmlEditing>
</dx:ASPxHtmlEditor>

The time the RTF content is processed on the server, a loading panel with the temporary HTML content is shown in the editor. The following example illustrates how to obtain the temporary HTML.

function onBeforePaste(s, e) {
  if(e.html.indexOf('id="dx-tmpRtf') > -1)
      alert("The temporary content will be pasted.");    
  else
      alert("Default behavior.");
}

Settings for images from the RTF content are specified by the HtmlEditorDefaultDialogSettings.InsertImageDialog property (provided that the ASPxHtmlEditorSettings.AllowSaveBinaryImageToServer property is set to true).

<SettingsDialogs>
    <InsertImageDialog>
        <SettingsImageUpload UploadStorage="...">
        </SettingsImageUpload>
    </InsertImageDialog>
</SettingsDialogs>

Note that with the enabled ProcessRtfContentPastingOnServer property, the ASPxClientHtmlEditor.BeforePaste and ASPxClientHtmlEditor.HtmlChanged client events are raised both before and after the content processing.

Known Limitations

See Also