Mehmood Hassan
Mehmood Hassan

Reputation: 147

Crystal report formula for adding/subtracting value from one field to another field

I have a report which has two fields: BOX and TRAYS, which are then summarize in each group using sum formula. And then there is a grand total of these fields are also shown. Now the problem is that I want to convert trays to boxes if their count increase from 12, and add 1 box to box field. If boxes are 2 and trays are 14 then the box field will change to 3 and trays field will change to 2. How can I achieve this?

Upvotes: 2

Views: 1533

Answers (1)

cojimarmiami
cojimarmiami

Reputation: 659

create 2 formulas(one per group and another for grand total) and sum int(your trays summary/12) + your box summary. That will return your desire result. int is going to round down the division between your trays summary and 12. Hope that help you

Upvotes: 2

Related Questions