Page Numbers

Hello.

I need to create a report with different pages number and is not necessary that initial page start in 1 (initial page and total pages are defined by the user). Also the page number format must be E-0001, E-002 depending of the page number. I had created a report with a page header and one TfrMemoview, this TfrMemoView will display a variable called Folio, at this moment I can assign an integer value to this variable but I can't assign a string value. Well I need your help to solve the following problems:

- How can I assign a string value into my variable folio.
- How can I create and print all pages defined by the user.
- I am using the child band beforeprint event to create a newpage but this instruction is creating pages without control, how can a declare how many pages I want to create?

Thank you very much for your help and excuse my spanglish.

Comments

  • edited 4:56AM
    Varibles in FR is allocated when used for first time, if this first time the variable folio is string you can assign any string value in the lufe of the variable, but if the variable in the first time is numeric in the future you can't use string

    take a look to the str function

    ej. folio := 'E'+ [str(mypagenumber)];

    to create controled new pages you can use this script

    totalnewpages := number defined any ware in the fr report definition
    for t := 1 to totalnewpages do begin
    new page
    end;

    make sure your child is not positioned inside a master data band or detail band. beacuase this script be execute each time the band iterate.
  • edited 4:56AM
    Hello d2Ortiz.

    Thank you very much for your explanation, it really help me and my report is working now.

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.