Greetings.
In my report, I'm grouping by Item_Code. For each group 12 rows are comming back (1 per month) in decending order.
I need to have 4 forumlas that do the following...
'// First
([Sum of first 3 months shipments] * 4)
/
(Sum of 3 months inventory)/3
'// Second
([Sum of first 3 months shipments] * 4)
/
(Sum of 6 months inventory)/6
'// Third
([Sum of first 3 months shipments] * 4)
/
(Sum of 9 months inventory)/9
'// Fourth
([Sum of first 3 months shipments] * 4)
/
(Sum of 12 months inventory)/12
The "numerator" for each group remains the same for each column
I made it work for 1 group using a function in the detail:
'//
WhilePrintingRecords;
Global NumberVar ShipmentSum;
NumberVar i:=0;
if RecordNumber < 4 then
ShipmentSum:= ShipmentSum + {TurnsOnly_ttx.MTD_Shipments};
'//
and in the group footer...
'//
Global NumberVar InventorySum3;
If RecordNumber < 4 then
InventorySum3 := InventorySum3 + {TurnsOnly_ttx.MTD_OnHand};
'//
Umm... this worked for 1 group, but not for the others... I'm a VB guru by nature, and I don't have a lot of experience with Crystal. Please Help
-T
In my report, I'm grouping by Item_Code. For each group 12 rows are comming back (1 per month) in decending order.
I need to have 4 forumlas that do the following...
'// First
([Sum of first 3 months shipments] * 4)
/
(Sum of 3 months inventory)/3
'// Second
([Sum of first 3 months shipments] * 4)
/
(Sum of 6 months inventory)/6
'// Third
([Sum of first 3 months shipments] * 4)
/
(Sum of 9 months inventory)/9
'// Fourth
([Sum of first 3 months shipments] * 4)
/
(Sum of 12 months inventory)/12
The "numerator" for each group remains the same for each column
I made it work for 1 group using a function in the detail:
'//
WhilePrintingRecords;
Global NumberVar ShipmentSum;
NumberVar i:=0;
if RecordNumber < 4 then
ShipmentSum:= ShipmentSum + {TurnsOnly_ttx.MTD_Shipments};
'//
and in the group footer...
'//
Global NumberVar InventorySum3;
If RecordNumber < 4 then
InventorySum3 := InventorySum3 + {TurnsOnly_ttx.MTD_OnHand};
'//
Umm... this worked for 1 group, but not for the others... I'm a VB guru by nature, and I don't have a lot of experience with Crystal. Please Help
-T