Joined: 20 Nov 2006
Online Status: Offline
Posts: 3701
Posted: 19 Nov 2015 at 4:38am
Assuming that you're grouping on account or something of the sort, sort the data on the start date descending. Then you'll use a couple of formulas something like this:
Put this formula in the Account group header - nothing will display, but we need it there to initialize the variables.
{@CalcRates}
WhilePrintingRecords;
NumberVar currentRate;
NumberVar prevRate;
if currentRate = 0 then
currentRate := {rate field}
else if prevRate = o then
prevRate := {rate field};
Then you'll need a third formula to do your actual calculation. It will look something like this:
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot delete your posts in this forum You cannot edit your posts in this forum You cannot create polls in this forum You cannot vote in polls in this forum