'Declaration Public Property SummaryDisplayArea As Nullable(Of SummaryDisplayAreas)
public Nullable<SummaryDisplayAreas> SummaryDisplayArea {get; set;}
SummaryDisplayArea property controls if and where summary calculation results for this field are displayed. You can also specify summary display area for individual summaries by setting SummaryDefinition's SummaryDefinition.DisplayArea property.
By default this property is resolved to TopLevelOnly and InGroupByRecords, which means that the summaries will be displayed in each group-by record (if there are group-by records) and for the top level records. See SummaryDisplayAreas enum for more information.
To enable the UI that lets the user select summary calculations to perform on fields, set the FieldSettings' AllowSummaries property. See AllowSummaries for more information.
Imports Infragistics.Windows Imports Infragistics.Windows.Editors Imports Infragistics.Windows.DataPresenter Private Sub Window1_Loaded(ByVal sender As Object, ByVal e As RoutedEventArgs) ' Set the data source. _dp.DataSource = _dataSource ' SummaryDisplayArea property specifies where summaries are to be displayed. See help ' for SummaryDisplayAreas enum for a listing of all available options and description ' of each option. ' ' This particular setting will display summary results at bottom of records (BottomFixed) ' and furthermore the summary record will be fixed or non-scrolling for the root level. ' If there group-by records, it will display summaries in each group-by record (InGroupByRecords) ' and furthermore the summary record will only be displayed for the top level only ' (TopLevelOnly) which is a desirable behavior because summaries of lower levels are ' displayed inside each group-by record. ' _dp.FieldSettings.SummaryDisplayArea = SummaryDisplayAreas.BottomFixed _ Or SummaryDisplayAreas.InGroupByRecords Or SummaryDisplayAreas.TopLevelOnly Dim summaryDef1 As SummaryDefinition = _dp.FieldLayouts(0).SummaryDefinitions.Add( _ "PriceAverage", SummaryCalculator.Average, "Price") ' You can override where a specific summary gets displayed by using the summary ' definition's DisplayArea property. ' summaryDef1.DisplayArea = SummaryDisplayAreas.TopFixed _ Or SummaryDisplayAreas.InGroupByRecords Or SummaryDisplayAreas.TopLevelOnly ' If DisplayArea is not specified, it will use the FieldSetting's SummaryDisplayArea ' property setting. ' Dim summaryDef2 As SummaryDefinition = _dp.FieldLayouts(0).SummaryDefinitions.Add( _ "PriceSum", SummaryCalculator.Sum, "Price") End Sub
using Infragistics.Windows; using Infragistics.Windows.Editors; using Infragistics.Windows.DataPresenter; public void Window1_Loaded( object sender, RoutedEventArgs e ) { // Set the data source. _dp.DataSource = _dataSource; // SummaryDisplayArea property specifies where summaries are to be displayed. See help // for SummaryDisplayAreas enum for a listing of all available options and description // of each option. // // This particular setting will display summary results at bottom of records (BottomFixed) // and furthermore the summary record will be fixed or non-scrolling for the root level. // If there group-by records, it will display summaries in each group-by record (InGroupByRecords) // and furthermore the summary record will only be displayed for the top level only // (TopLevelOnly) which is a desirable behavior because summaries of lower levels are // displayed inside each group-by record. // _dp.FieldSettings.SummaryDisplayArea = SummaryDisplayAreas.BottomFixed | SummaryDisplayAreas.InGroupByRecords | SummaryDisplayAreas.TopLevelOnly; SummaryDefinition summaryDef1 = _dp.FieldLayouts[0].SummaryDefinitions.Add( "PriceAverage", SummaryCalculator.Average, "Price" ); // You can override where a specific summary gets displayed by using the summary // definition's DisplayArea property. // summaryDef1.DisplayArea = SummaryDisplayAreas.TopFixed | SummaryDisplayAreas.InGroupByRecords | SummaryDisplayAreas.TopLevelOnly; // If DisplayArea is not specified, it will use the FieldSetting's SummaryDisplayArea // property setting. // SummaryDefinition summaryDef2 = _dp.FieldLayouts[0].SummaryDefinitions.Add( "PriceSum", SummaryCalculator.Sum, "Price" ); }
Target Platforms: Windows 10, Windows 8.1, Windows 8, Windows 7, Windows Server 2012, Windows Vista SP1 or later, Windows XP SP3, Windows Server 2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or later), Windows Server 2003 SP2