Summary
The Summary class is used to define sums in RecordsView control. Summary can be used in RecordsView in conjunction with Grouping.
Constructor:
constructor( field: string | Field, kind?: SummaryKind, pos?: SummaryPosition, format?: string )
Creates a Summary object instance.field: string | Field
Can be a text or a field object like Contract.amount.kind: SummaryKind
(optional)
The type of summary to calculate, such as SummaryKind.Sum, SummaryKind.Avg, SummaryKind.Count, etc. The default is SummaryKind.Sum.pos: SummaryPosition
(optional)
The position of the summary (e.g., in the header or footer). Possible values are SummaryPosition.Footer, SummaryPosition.Group, SummaryPosition.GroupFooter, Default is SummaryPosition.Footer. For summary positions SummaryPosition.Group and SummaryPosition.GroupFooter, grouping must be defined on those fields first.format: string
(optional)
The format in which to display the summary. Examples of formattings (read more about formatting):- $,0.00 - will display $ sign before the value
- $,0.00;-$,0.00 - the same as first one but allows negative values too
- #.00 - will force 2 decimals in the value
- 00.## - will force extra zeros to the left
- AVG=0.00
- SUM=0.00
- COUNT=0