Jump to content
Server Maintenance This Week. ×

Count required amount of pages


Ralph Schwegler

This topic is 4989 days old. Please don't post here. Open a new topic instead.

Recommended Posts

Hi folx

I have a file invoices with n invoice line, each being max 3 lines long.

How can I figure out how many pages I will need, and how can I manage this?

As far as I understand, printing will be from a layout of the invoice lines. But what else?

Thank you for your valued help.

Link to comment
Share on other sites

Your question suggests that you are not familiar with certain FM features and techniques.

Yes, invoices are best printed from their child line items table. If each line item can be 3 lines long, then you need to make that field tall enough. However, you can use FM's Slide feature to remove white space as well as reduce the size of the body part.

Check out Sliding.

Link to comment
Share on other sites

I think I understand your problem.

I use a script to:

count no of items in portal using global $$lines

set $$page to 1

Set $$pageof to 1

If $$lines < = lines on invoice (1-5)

print invoice

if $$lines < = next page of invoice (6-10)

set $$page to 1

set $$pageof to 2

print

set $$page to 2

set page of to 2

print

etc.

The portal must be set up to change initial rows and number of rows to print for each page.

Link to comment
Share on other sites

IEW, are you printing multiple portals? Why? You should print from the line items table.

As for having Page 1 of 2 in a footer, all you need to do is Enter Preview, Go to Last Page, and set a global (gPages) to the Page Number. Then put Page ## or gPages in your footer.

Link to comment
Share on other sites

There is technique for end of page summaries (it's not straightforward). I'll see if I can find the thread. If "comment" sees this, perhaps he'll post a link to it, as I believe he's the person who created it.

End of section totals can be created using a trailing sub-summary. End of report, trailing grand summary.

Link to comment
Share on other sites

This topic is 4989 days old. Please don't post here. Open a new topic instead.

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.