Data values in PageFooter of last page come from NEXT Master record
Using the latest FR FMX2 and Delphi 10.3.3, I have values from the Master data and the SubDetail data in a PageFooter. The report has Master, Detail, SubDetail, and a chain of Child bands that all get data from the SubDetail source.
I am using Report.PreviewPages.AddFrom to append output from multiple report sources. This works well in every way except this issue with the PageFooter. Depending on what records are included in the report, the bad PageFooter may appear on the last page of the output, or on the last page of one report, just ahead of the same report or a different report being appended in again (using AddFrom) with different records.
The values in the PageFooter are all as expected except on the last page of a report, where the Master values come from the NEXT record in that table, and this happens if that next record is in the report (the next page) or NOT included in the report at all and the report ends with the bad PageFooter.
If this is a timing issue, is there a better approach to repeating some Master data in a PageFooter? Would it make sense to use a JOIN in the data so that the Master fields needed in the PageFooter could be gotten from the SubDetail record instead of from the Master?