Embedded BI Publisher for JDE and dynamic page re-sizing (XSL-FO Stylesheet)



We have a requirement from a customer to have a RTF Template for invoices to dynamically change the page size, based on the company location where it is processing. In other words, for the US location, invoices need to print with a page size="letter", whereas all other locations the invoices need to print as page size="A4" with the same template.

I reviewed this requirement and have been utilizing the approach by modifying the XSL-FO stylesheet (which is exported from the Invoice RTF Template).

This approach worked when testing on a local machine. Based on customer location, a local test allowed the invoice to print "A4" or "letter" dynamically (which I tested this using the "Template Viewer" tool on a local standalone windows machine).

However, when trying to install this onto a JDE server, by setting up a XMLP repository object (XSL object type - P95600), I found that this does not work. I also found, that the report definition (P95620) containing the XSL XMLP Repository object, does not allow PDF output (greyed out under output options).

With BI Publisher Enterprise Standalone, the XSL-FO stylesheet can be configured to output either as PDF or XML.

It seems that this does not work with BI Publisher Embedded with JDE and is not supported.

Can anyone provide suggestions (or possible solutions) on how to approach this requirement. The RTF has to dynamically change page size when processing via BIP based on condition (instead of needing to create a new RTF).

Any response will be much appreciated.

JDE Tools Release: (


Well Known Member
I know you don't like multiple RTFs... But hear me out...

Have 2 RTFs. Each RTF contains a call to a subtemplate - say procMAIN. 1 RTF is sized for Letter. The other RTF is sized for A4. The subtemplate procMAIN contains all the logic to process the XML.

This is possible because when you call a subtemplate that accepts parameters, you can pass simple values, like text, numbers, dates; or complex values, i.e. entire nodes. Remember, everything in XML is a node.

All the template logic stays in 1 place, the subtemplate. The other 2 are just wrappers that determine the paper size.


Hi Jileto,

Thank you very much for this suggestion! :) It is a brilliant idea and makes sense that this approach will work.

Much appreciated