Skip to main content

PastedImageSavingEventArgs.InnerHTML Property

Gets or sets HTML content (inner HTML) that will be rendered inside the HTML tag specified in the PastedImageSavingEventArgs.TagName property.

Namespace: DevExpress.Web.ASPxHtmlEditor

Assembly: DevExpress.Web.ASPxHtmlEditor.v24.1.dll

NuGet Package: DevExpress.Web

Declaration

public string InnerHTML { get; set; }

Property Value

Type Description
String

A string value specifying the HTML content.

Remarks

Note

The InnerHTML property is not in effect if the PastedImageSavingEventArgs.TagName property is not specified or contains the ‘img’ tag.

The following example illustrates how to use the ASPxHtmlEditor.PastedImageSaving event and the InnerHTML property to process the pasted binary image and change its render result.

protected void ASPxHtmlEditor1_PastedImageSaving(object source, PastedImageSavingEventArgs e) {
    if (!e.IsValid) {
        e.TagName = "DIV";
        e.InnerHTML = "<img src='broken-image.png' />";
        e.SetStyleAttribute("border", "1px dotted #f00");
    }
}
See Also