TreeListSummaryItem Class

A summary item.

Namespace: DevExpress.Xpf.Grid

Assembly: DevExpress.Xpf.Grid.v21.1.dll

Declaration

public class TreeListSummaryItem :
    SummaryItemBase

The following members accept/return TreeListSummaryItem objects:

Remarks

The DXTreeList allows you to display concise information about individual columns. For instance, you can display the total number of nodes or maximum value, etc. This is called a summary.

The DXTreeList supports the Total Summary type. It stores total summary items within the DevExpress.Xpf.Grid.TreeListControl.TotalSummary collection. Individual summary items are represented by the TreeListSummaryItem objects.

To learn more, see Data Summaries.

Example

This example shows how to display totals. It is shown how to create summary items in code-behind and XAML.

View Example

<Window x:Class="DXTreeList_Totals.MainWindow"
        xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
        xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
        Title="MainWindow" Height="350" Width="525"
        xmlns:dxg="http://schemas.devexpress.com/winfx/2008/xaml/grid">
    <Grid>
        <dxg:TreeListControl Name="treeListControl1" AutoPopulateColumns="True">
            <dxg:TreeListControl.View>
                <dxg:TreeListView Name="treeListView1" AutoWidth="True"
                                  KeyFieldName="ID" ParentFieldName="ParentID"
                                  ShowTotalSummary="True"/>
            </dxg:TreeListControl.View>
            <dxg:TreeListControl.TotalSummary>
                <dxg:TreeListSummaryItem FieldName="Name" SummaryType="Count" />
            </dxg:TreeListControl.TotalSummary>
        </dxg:TreeListControl>
    </Grid>
</Window>
See Also