GrapeCity MultiRow Windows Forms Documentation
CellName Property (MathStatistics)
Example 


Gets or sets the cell name of the cell value used in the statistic.
Syntax
<DefaultValueAttribute()>
<TypeConverterAttribute("GrapeCity.Win.MultiRow.Design.CellNameTypeConverter, GrapeCity.Win.MultiRow, Version=7.20.20141.0, Culture=neutral, PublicKeyToken=0f7a722ee3c2bdd9")>
<RefreshPropertiesAttribute(RefreshProperties.All)>
<SRDescriptionAttribute("Indicates which cell's value takes part in the statistic by using the cell name.")>
Public Property CellName As String
Dim instance As MathStatistics
Dim value As String
 
instance.CellName = value
 
value = instance.CellName
[DefaultValue()]
[TypeConverter("GrapeCity.Win.MultiRow.Design.CellNameTypeConverter, GrapeCity.Win.MultiRow, Version=7.20.20141.0, Culture=neutral, PublicKeyToken=0f7a722ee3c2bdd9")]
[RefreshProperties(RefreshProperties.All)]
[SRDescription("Indicates which cell's value takes part in the statistic by using the cell name.")]
public string CellName {get; set;}

Property Value

A System.String value that represents the cell name. The default is String.Empty.
Example
The following code example shows how to customize the summary cell's calculation logic. This code example is part of a larger example provided for the SummaryCell class.
private SummaryCell CreateTotalSummaryCell()
        {
            // Calculate sum of subtotal in all rows.
            SummaryCell summaryCell = new SummaryCell();
            summaryCell.Name = "Total";
            summaryCell.Calculation = new MathStatistics(StatisticsType.Sum, "SubTotal", true);
            summaryCell.Style.Format = "C";
            summaryCell.Style.BackColor = Color.Wheat;
            return summaryCell;
        }
Private Function CreateTotalSummaryCell() As SummaryCell
        ' Calculate sum of subtotal in all rows.
        Dim summaryCell As New SummaryCell()
        summaryCell.Name = "Total"
        summaryCell.Calculation = New MathStatistics(StatisticsType.Sum, "SubTotal", True)
        summaryCell.Style.Format = "C"
        summaryCell.Style.BackColor = Color.Wheat
        Return summaryCell
    End Function
Requirements

Target Platforms: Windows 7, 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

See Also

Reference

MathStatistics Class
MathStatistics Members

 

 


Copyright © GrapeCity, inc. All rights reserved.