IPrxTableIslandGroupingMethod.Method

Syntax

Method : BasicAggregatorOperation;

Description

The Method property determines a method of data grouping.

Example

Sub Main;

Var

MB: IMetabase;

MObj : IMetabaseObject;

Report : IPrxReport;

TabIs : IPrxTableIslands;

TI : IPrxTableIsland;

Grs : IPrxTableIslandGroupings;

Gr : IPrxTableIslandGrouping;

GrT : IPrxTableIslandGroupingTotals;

Method : IPrxTableIslandGroupingMethod;

Begin

MB := MetabaseClass.Active;

MObj := MB.ItemById("Report").Edit;

Report := MObj As IPrxReport;

TabIs := Report.TableIslands;

TI := TabIs.Item(0);

TI := Ti.Edit;

Grs := TI.Groupings;

Gr := Grs.Item(0);

GrT := Gr.Totals;

Method := GrT.Method(TI.Layout.Rows(0).Cells(0));

Method.Method := BasicAggregatorOperation.Sum;

Method.Cell.ColumnSpan := 2;

Method.Field.FieldName := TI.Source.Execute.Fields.Item(2).Name;

Method.Totals.Caption.AsString := Gr.Caption.AsString;

TI.Save;

MObj.Save;

End Sub Main;

After executing the example the specified totals parameters are set up. Report - identifier of the regular report, which sheet contains a relational data area.

See also:

IPrxTableIslandGroupingMethod