freemarker - Netsuite PDF Templating: get number of pages as attribute -
i templating pdfs in netsuite using freemarker , want display footer on last page. have been doing research, couldn't find solution (since looks environment not allow me include or import libs), thought comparing number of page total pages in if tag nice , easy workaround. know how display numbers using <pagenumber/>
, <totalpages/>
tags, still cannot them values can use them this:
<#if (pagenumber == totalpages) > ... footer html... </#if>
any ideas of how or can values from?
the approach trying won't work, because mixing bfo , freemarker syntax. netsuite uses 2 different "engines" process pdf templates. first step freemarker, merges record fields template , produces xml file, converted bfo pdf file. <totalpages/>
element meaningless freemarker, converted number bfo later.
unfortunately, ability add footer last page of document limitation of bfo, per bfo faq:
at moment not have facility explicitly assigning footer or header last page in document when number of pages unknown.