Regarding PrintOnFirstPage

I want to print a header on first page, but no the rest page. So, I set the PrintOnFirstPage to True, the result is the first page was not print the header but printed on the rest pages.

After I checked the source code, I found a condition for this option in frxEngine.pas as the following:
    if FIsFirstPage and (Band is TfrxPageHeader) and
      not TfrxPageHeader(Band).PrintOnFirstPage then
    begin
      if Band.PrintChildIfInvisible then
        Band := Band.Child
      else
        continue;
    end;

So, I change the condition from
    if FIsFirstPage and (Band is TfrxPageHeader) and
      not TfrxPageHeader(Band).PrintOnFirstPage then

to

    if not FIsFirstPage and (Band is TfrxPageHeader) and
      TfrxPageHeader(Band).PrintOnFirstPage then


After recompile, the header is printed on the first page but not the rest pages.

I'm not sure this is correct modification, because of the whole process flow, but the result is what I needed.

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.