HasTotals: Boolean;
The HasTotals property returns True if the Totals option is enabled.
The following example assumes that there is the Report object with the IPrxReport type.
Sub UserProc;
Var
Report: IPrxReport;
DIs: IPrxDataIslands;
DI: IPrxDataIsland;
Prop: IPrxDataIslandProperties;
Dim : IDimInstance;
DimProp : IPrxDataIslandDimension;
Totals : IPrxDataIslandTotals;
Begin
DIs := Report.DataIslands;
DI := DIs.Item(0).Edit;
Prop := DI.Properties;
Dim := DI.Slice.LeftHeader.Item(0).Dimension;
DimProp := Prop.Dimension(Dim.Dimension);
Totals := DimProp.HierarchyTotals;
If Totals.HasTotals Then
Totals.Totals := TriState.OffOption;
DI.Save;
End If;
End Sub UserProc;
After executing the example the Totals By Hierarchy option is disabled if it was enabled up to that moment.
See also: