Fix row count inside Fast Report

edited 10:22AM in FastReport 4.0
Hi All,
we have a problem below:
We use Fast Report to design the invoice (with pre-defined form).
we need fix the row count of goods items on each page = 7 (it means after 7 lines system should print to new page).
on the last page. it should print the rest of lines and the general information of invoice (summary) like: total money to pay, money in word, name of cashier,...all the general info should be on the fixed position (at the bottom of the last page).
what we should do for that thing? We try to call function TfrxCustomEngine.NewPage inside the event OnBeforePrint of the band, but system got errors after 6 lines printed.

Comments

  • edited 10:22AM
    I attached 3 examples of my tests. I tried do make some memos (lying on PageFooter) visible or NOT by comparing total rows printed on Masterband with the number of total rows of the query use for Masterband.

    I use
    => PageHeaderOnBeforePrint even to set LinesOnPage to 1
    => MasterBandOnBeforePrint to increase LinesOnPage
    => PageFooterOnBeforePrint to make Memos visible or not

    And finaly - like you - I use Engine.NewPage when LinesOnPage is more then 7 => this is done in MasterBandOnBeforePrint event.

    Your FR script is so COMPLICATED and maybe it is the source of the error you get.

    Mick

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.