windowsforms-devexpress-dot-xtratreelist-dot-treelistoptionsview-76f034ec.md
Gets or sets the number of data nodes whose content is processed to apply best fit to columns.
Namespace : DevExpress.XtraTreeList
Assembly : DevExpress.XtraTreeList.v25.2.dll
NuGet Packages : DevExpress.Win.Navigation, DevExpress.Win.TreeList
[DefaultValue(-1)]
[XtraSerializableProperty]
public virtual int BestFitMaxNodeCount { get; set; }
<DefaultValue(-1)>
<XtraSerializableProperty>
Public Overridable Property BestFitMaxNodeCount As Integer
| Type | Default | Description |
|---|---|---|
| Int32 | -1 |
An integer value specifying the number of data nodes that are processed to apply best fit to columns.
|
You can access this nested property as listed below:
| Object Type | Path to BestFitMaxNodeCount |
|---|---|
| TreeList |
.OptionsView .BestFitMaxNodeCount
|
When applying the best fit feature to a column, the column is resized so that it displays the complete contents of its header, footer cell and data cells. The number of data nodes taken into account for this calculation is specified by the BestFitMaxNodeCount property:
Note
Setting the BestFitMaxNodeCount property to a non-default value automatically sets the TreeListOptionsView.BestFitNodes property to Custom. To use the All , Visible or Display mode, reset the BestFitMaxNodeCount property to its default value.
You can apply the best fit feature to columns using the TreeList.BestFitColumns or TreeListColumn.BestFit methods. End-users can also use the best fit feature via the column header context menu.
See Also