I have been struggling with xls-fo because of a severe lack of examples.
I want to generate a dynamic invoice which has the grand total at the bottom of the page.
I have been trying with height="100%" with block-container and table, then try to set position relative to the bottom. The interpreter doesn't recognise percentage height and I have no luck at all.
Relative positioning also doesn't work. I don't know the right syntax. I can see some work has been done with fo:conditional-page-master-reference. I don't even know how to apply for that page-sequence-master.
Can you give me the simplest working xsl-fo structure for this layout?



The simplest way would be to generate an
fo:footnoteat the end of the lastfo:block. There are multiplefo:footnoteexamples at https://www.antennahouse.com/xsl-fo-samples.If you are using Antenna House Formatter, you could make an
fo:floatthat floats to the bottom of the page. See https://www.antenna.co.jp/AHF/help/en/ahf-float.htmlThe
fo:conditional-page-master-referenceway would also work. There's also a sample for that at https://www.antennahouse.com/xsl-fo-samples.To get the grand total into the footer of the only or last page would also require that you use
fo:static-content,fo:marker, andfo:retrieve-marker. There's alsofo:markersamples, plus markers are covered in "How to Develop Stylesheets for XML to XSL-FO Transformation" available at https://www.antennahouse.com/xml-to-xsl-fo-stylesheets.