0

I know this is a very basic question but I am simply stuck here. I should be beyond this problem but i can't find a way.

Tables:

  • Customers (pk)
  • Invoices (pk, Customersfk)
  • InvoiceLineItems (Invoicefk,Servicesfk)
  • Services (pk)

In my invoice print layout I have a leading and a following grand summary. Inbetween those I have my body. In that body I have the amount (lineitems), the description (services), unit price (services) and sub sum (lineitems).

It works fine, for one lineitem, but when I have more than one lineitem for one invoice the body doesn't expand. Filemaker online help says the following:

Body: Each object you put in the body, including fields, text objects, and graphics, appears once for each record in the found set. You can have only one body in a layout.

The print layout shows records from invoices. When I make a portal big enough for the entries it shows all positions.

There must be a tiny thing I overlook. I tried to analyse the starter solutions, checked the relationships and compared the layout options in the inspector. So far no luck.

Any help is appreciated. Thx in advance.

Sarnu
  • 13
  • 1
  • 3

1 Answers1

0

The print layout shows records from invoices.

That is a mistake. Your print layout should be based on the InvoiceLineItems table.

To print an invoice, you need a script that goes to related record (from InvoiceLineItems, Show only related records). Thus you'll have a found set of the selected invoice's line items, which you will print out in list view. Place the invoice's details in the sub-summary parts. Do not use portals for printing.

michael.hor257k
  • 113,275
  • 6
  • 33
  • 51
  • Thank you for the answer. I changed the dependence to lineitems, however I now got the problem that it has two found records but displays them independantly instead of all in one layout. Also when I use the script step to go to the layout and show only related records, I ahve the same issue. – Sarnu Aug 13 '14 at 07:49
  • @Sarnu As I said, your print layout needs to be in **list view**. – michael.hor257k Aug 13 '14 at 07:51