A very commoun requirement is to have a page footer with the subtotal
of the items in the current and previous pages and a total amount at the
end of the document. The running totals example located in
shows how create the subtotal item at the end of each page. The output
of this example is a 2 page document, in the first page the label
"Subtotal" will be generated, together with the sum of all items in the
in the second page the text is "Total" and the value is the sum of all
items in the document.
to achieve this result, two items in the detail area must be selected,
one will be theLineAmountfield which
needs to be summed up, and the other can be any field, in this case the
article field has been taken:
The LineAmount field has the property Use for Subtotal set
Yesand the subtotal typeSUMwill cause the values of this field to be summed up during the
The Article field will be used to create the "subtotal" and
"total" labels. Note the subtotal type is now CONSTANT and
two constant value fields have been filled with the correct value.
To finish up the set up, the 2 fields in the page footer must reference
the subtotal field in the detail section.