how do i subtract two grandtotal fields in Crystal

2019-08-26 13:16发布

I'm using crystal reports and i have created two sum grandtotal fields. Now i want to do field 1 - field 2 in a X1 formula, but i can't call those fields into the formula. So I tried to use Sum({field1}) - 2 but that doesn't seem to get the grandtotal.

Is it possible to do a grandtotal in a sum like Sum({field1}.GrandTotal) ?

1条回答
一纸荒年 Trace。
2楼-- · 2019-08-26 13:45

create a formula and write

Sum({field1}-Sum({field2}

and place at rigt most part that is after all columns.

If this doesn't work then follow below process.


Crate a formula @Grandtotal1

Sum({field1},{Group1}(if using group)

create a formula @Grandtotal2

Sum({field1},{Group2}(if using group)

Now create another formula

EvaluateAfter(@Grandtotal1);
EvaluateAfter(@Grandtotal2)

@Grandtotal1+@Grandtotal2
查看更多
登录 后发表回答