Hi,
The data I am trying to print on the web looks as follows:
Date 1
Record 1
Record 2
Record 3
Date 2
Record 1
Record 2
Record 3
and onwards ..........................
This I have working fine.
I need to add a calculation into the page print, so the page looks
like:
Date 1 (There are 437 units this week)
Record 1
Record 2
Record 3
Date 2 (There are 821 units this week)
Record 1
Record 2
Record 3
PROBLEM:
The calculation is done by stuffing a variable at the end of the loop,
and then calling a function which prints either 'No Data' or 'There are
xxx units this week'
Because the calculation has to be done at the end of the record loop
before the date changes, when the page first loads, the first date
header always reads:
Date 1 (No Data)
Record 1
Record 2
Record 3
Which is true, because the code has not yet looped through that dates
records, and hence the calculation = 0. Except there is a value. How
can I get around this problem ??
The calculation for the 1st date in the recordset is always printed
against the 2nd date header and so on down the listing. This is
obvious, as on the second loop, the first calculation has been done,
and gets printed when the next date header is created.... :-(
Much confused. I have tried everything I know.
Thanks in advance
David