MESCIUS.ActiveReports Assembly / GrapeCity.ActiveReports Namespace / SectionReport Class / CalculatedFields Property
Example

CalculatedFields Property
Gets a FieldCollection object containing all of the calculated fields in the report.
Syntax
'Declaration
 
Public ReadOnly Property CalculatedFields As FieldCollection
 

Property Value

A GrapeCity.ActiveReports.Data.FieldCollection value, with calculated fields.
Remarks
SectionReport can calculate simple arithmetic formulas.
Example
var sectionReport = new GrapeCity.ActiveReports.SectionReport();
sectionReport.LoadLayout(reportFilePath);
sectionReport.Document.Printer.PrinterName = String.Empty;
var calculated = new GrapeCity.ActiveReports.Data.Field();
calculated.DefaultValue = null;
calculated.FieldType = FieldTypeEnum.None;
calculated.Formula = "=number*2";
calculated.Name = "DoubleNumber";
calculated.Tag = null;
sectionReport.CalculatedFields.Add(calculated);
See Also