reset page number while merging multiple FR3 files

edited June 2018 in FastReport VCL 5
hello,
how can I reset the TOTAL page number for the second FR3 file in code?
in the generated PDF file, the second report(report.fr3)'s page number starts from 1, but the total page number is including the page from invoice.fr3.

frxReport.LoadFromFile('invoice.fr3');
frxReport.PrepareReport(true);
frxReport.LoadFromFile('report.fr3');
frxReport.PrepareReport(false);
MainDM.frxPDFExport1.FileName:=Savedialog1.FileName;
frxReport.Export(MainDM.frxPDFExport1);

thanks

Comments

  • PolomintPolomint Australia
    edited June 2018
    Just to be clear, are you asking for each sub-report to be numbered independently, or do you want the numbering to be "seamless"?

    For example, say Invoice is one page, and Report is three pages, do you want the four pages in the PDF numbered:

    A/ 1 of 1; 1 of 3; 2 of 3; 3 of 3?
    B/ 1 of 4; 2 of 4; 3 of 4; 4 of 4?
    C/ another scheme?

    We went on a journey last year with "seamless" numbering which you can find discussed at:

    https://www.fast-report.com/en/forum/index....mp;hl=Composite

    You might be able to use a similar approach...

    Cheers, Paul
  • edited 4:16PM
    Polomint wrote: »
    Just to be clear, are you asking for each sub-report to be numbered independently, or do you want the numbering to be "seamless"?

    For example, say Invoice is one page, and Report is three pages, do you want the four pages in the PDF numbered:

    A/ 1 of 1; 1 of 3; 2 of 3; 3 of 3?
    B/ 1 of 4; 2 of 4; 3 of 4; 4 of 4?
    C/ another scheme?

    We went on a journey last year with "seamless" numbering which you can find discussed at:

    https://www.fast-report.com/en/forum/index....mp;hl=Composite

    You might be able to use a similar approach...

    Cheers, Paul

    I want it A, and I will read your link now. Thanks.
  • edited 4:16PM
    Just to be clear, are you asking for each sub-report to be numbered independently, or do you want the numbering to be "seamless"!
    wuxiaworld
  • edited 4:16PM
    mary rosie wrote: »
    Just to be clear, are you asking for each sub-report to be numbered independently, or do you want the numbering to be "seamless"!
    wuxiaworld

    to be numbered independently.
    Say i have a invoice.fr3, with only 1 page.
    and followed by report.fr3, with 3 pages
    I want the numbers are

    Page 1 of 1
    Page 1 of 3
    Page 2 of 3
    Page 3 of 3
  • edited 4:16PM
    kccheng wrote: »
    kccheng wrote: »
    Just to be clear, are you asking for each sub-report to be numbered independently, or do you want the numbering to be "seamless"!
    wuxiaworld

    to be numbered independently.
    Say i have a invoice.fr3, with only 1 page.
    and followed by report.fr3, with 3 pages
    I want the numbers are

    Page 1 of 1
    Page 1 of 3
    Page 2 of 3
    Page 3 of 3


    Was this ever resolved or did you find a way to do this? I'm in the same spot. We will print out multiple reports for different customers and it will number them 1-99 (for example) across all reports. It doesn't make sense that the final report starts on page 97 (again, for example) when it should be numbered 1-3.

    ALSO, have you found a way to label each report # OF # as in your example above? It's nice to know if we're missing any pages at the end of each report.

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.