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?

Leave a Comment

Rich Text Editor. To edit a paragraph's style, hit tab to get to the paragraph menu. From there you will be able to pick one style. Nothing defaults to paragraph. An inline formatting menu will show up when you select text. Hit tab to get into that menu. Some elements, such as rich link embeds, images, loading indicators, and error messages may get inserted into the editor. You may navigate to these using the arrow keys inside of the editor and delete them with the delete or backspace key.