The manual






Summary sheet

I call a summary sheet a sheet in which certain fields are the result of a calculation carried out on a set of other sheets.

Here is a simplified customer file:

The objective here is for the 'ca' field to be updated automatically with the total amount of invoices associated with the customer.

Suppose that we have created a report (whose identifier will be 'xxx / yyy / zzz' in the program below) which lists all customer invoices, for example:

Here is the 'Fields' tab of the definition of this report.
Please note that the report column which contains the amount of each invoice has in this report the identifier 'total' and not 'amount', which is the consequence of a choice made when creating the forms. For more details, refer to the document 'The sheets and their programs'.

All you have to do is add the following code to the contact form so that the 'ca' field is automatically updated:

ca := 0
report "xxx/yyy/zzz" client client
  field Float total
  ca += total