CreateTotals

sabzamsabzam Member Posts: 1,149
Hi Everybody,

I'm trying to use the CreateTotal in a report which adds up the Line Amount solely when the Line Amount is Negative. Is this possible?

Comments

  • BBlueBBlue Member Posts: 90
    Hello,

    You can have in OnAfterGetRecord of the specific DataItem:
    IF "Line Amount" < 0 THEN
      NegativeAmt := Line Amount;
    

    and in OnPreDataItem of that DataItem:
    CurrReport.CREATETOTALS(NegativeAmt);
    

    where NegativeAmt is decimal type.

    Hope I understood what you want to achieve...
    //Bogdan
Sign In or Register to comment.