When the ClientDataSet is opened the value of the aggregate field is correct. However, the user can change the IndexFieldName to sort the grid.
When this happens the value of the aggregate field appears doubled.
This is the configuration of the aggregate field:
Code: Select all
wwClientDataSetExtratoSumCalcVALMOVTO.Active := True;
wwClientDataSetExtratoSumCalcVALMOVTO.IndexName := '';
wwClientDataSetExtratoSumCalcVALMOVTO.GroupingLevel := 0;