Master datail band

edited September 2012 in FastReport 4.0
Hi !

I have a report with master detail band. Can I print the master data to every page when a detail band doesn't fit to one page?
Thx in advance.

Comments

  • edited September 2012
    I found the solution. I created a groupheader band and moved the fields from masterdata band to it and hid masterdata.
  • gpigpi
    edited 10:53PM
    Use additional TfrxHeader band for DetailData and set TfrxHeader.ReprintOnNewPage to True
    procedure MasterData1OnAfterPrint(Sender: TfrxComponent);
    begin
      Header1.Visible := False;                                                    
    end;
    
    procedure DetailData1OnAfterPrint(Sender: TfrxComponent);
    begin
      Header1.Visible := True;  
    end;
    
  • edited 10:53PM
    gpi wrote: »
    Use additional TfrxHeader band for DetailData and set TfrxHeader.ReprintOnNewPage to True
    procedure MasterData1OnAfterPrint(Sender: TfrxComponent);
    begin
      Header1.Visible := False;                                                    
    end;
    
    procedure DetailData1OnAfterPrint(Sender: TfrxComponent);
    begin
      Header1.Visible := True;  
    end;
    

    Thanks gpi!

    My problem is I generate reports at runtime and I use fastreport wich shipped with delphi xe2. Probably scripts doesn't work with that version.

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.