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

TreeListOptionsView.AllowHtmlDrawHeaders Property

Gets or sets whether HTML formatting can be applied to column and band captions.

Namespace: DevExpress.XtraTreeList

Assembly: DevExpress.XtraTreeList.v19.1.dll

Declaration

[DefaultValue(false)]
[XtraSerializableProperty]
public virtual bool AllowHtmlDrawHeaders { get; set; }

Property Value

Type Default Description
Boolean **false**

true if HTML formatting can be applied to column and band captions; otherwise, false.

Property Paths

You can access this nested property as listed below:

Library Object Type Path to AllowHtmlDrawHeaders
WinForms Controls ResourcesTree
.OptionsView.AllowHtmlDrawHeaders
TreeList
.OptionsView.AllowHtmlDrawHeaders
Reporting XRDesignFieldList
.OptionsView.AllowHtmlDrawHeaders
XRDesignReportExplorer
.OptionsView.AllowHtmlDrawHeaders

Remarks

If the AllowHtmlDrawHeaders property is set to true, you can use HTML tags to format the TreeListColumn.Caption and TreeListBand.Caption. For detailed information see HTML Text Formatting.

Example

The following example shows how to display an image to the right of the Job Title column’s caption using HTML tags. The HTML formatting feature is enabled via the TreeListOptionsView.AllowHtmlDrawHeaders property.

TreeList-HtmlImages-ex

string imageName = "customer";
imageCollection1.AddImage(Image.FromFile("c:\\customer-16x16.png"), imageName);

treeList1.OptionsView.AllowHtmlDrawHeaders = true;
treeList1.HtmlImages = imageCollection1;
colJobTitle.Caption = colJobTitle.GetCaption() + "<image=" + imageName + ">";
See Also