Back to Devexpress

HtmlDocumentExporterOptions.ExportRootTag Property

officefileapi-devexpress-dot-xtrarichedit-dot-export-dot-htmldocumentexporteroptions-008240b3.md

latest4.3 KB
Original Source

HtmlDocumentExporterOptions.ExportRootTag Property

Gets or sets the root tag of the HTML document to start the export.

Namespace : DevExpress.XtraRichEdit.Export

Assembly : DevExpress.RichEdit.v25.2.Core.dll

NuGet Package : DevExpress.RichEdit.Core

Declaration

csharp
public ExportRootTag ExportRootTag { get; set; }
vb
Public Property ExportRootTag As ExportRootTag

Property Value

TypeDescription
ExportRootTag

An ExportRootTag enumeration value specifying the HTML document tag.

|

Available values:

NameDescription
Html

Specifies the <HTML> tag as the root tag for export.

| | Body |

Specifies the <BODY> tag as the root tag for export.

|

Property Paths

You can access this nested property as listed below:

Object TypePath to ExportRootTag
RichEditDocumentExportOptions

.Html .ExportRootTag

|

Remarks

Specify the ExportRootTag and the HtmlDocumentExporterOptions.CssPropertiesExportType settings to perform the export to HTML, via the HtmlExporterBase.Export method.

The following code snippets (auto-collected from DevExpress Examples) contain references to the ExportRootTag property.

Note

The algorithm used to collect these code examples remains a work in progress. Accordingly, the links and snippets below may produce inaccurate results. If you encounter an issue with code examples below, please use the feedback form on this page to report the issue.

how-to-customize-copy-and-paste-commands/CS/RichEditCustomCopyPaste/CustomCommands.cs#L22

csharp
richEditControl.Options.Export.Html.ExportRootTag = ExportRootTag.Html;

word-processing-customize-html-export/CS/Program.cs#L66

csharp
HtmlDocumentExporterOptions options = new HtmlDocumentExporterOptions();
options.ExportRootTag = htmlExportType;
options.CssPropertiesExportType = cssExportType;

how-to-customize-copy-and-paste-commands/VB/CustomCommands.vb#L24

vb
richEditControl.Options.Export.Html.ExportRootTag = ExportRootTag.Html

word-processing-customize-html-export/VB/Program.vb#L64

vb
Dim options As New HtmlDocumentExporterOptions()
options.ExportRootTag = htmlExportType
options.CssPropertiesExportType = cssExportType

See Also

Export

CssPropertiesExportType

HtmlDocumentExporterOptions Class

HtmlDocumentExporterOptions Members

DevExpress.XtraRichEdit.Export Namespace