Reports using xsl:fo - include external pdf
Not strictly an Apex question, but posted here as the application is in Apex.
I have a report layout defined in xsl:fo in my application. As part of this report, I also need to pick up an external pdf file (scanned document) and print with the report. I have added the external document to my fo definition as follows:
<fo:page-sequence master-reference="portraitblank">
<fo:flow flow-name="region-body">
<fo:block>
<fox:external-document content-type="pdf" src="url('http://myhostaddress:8088/filepath/docname.pdf')" />
</fo:block>
</fo:flow>
</fo:page-sequence>
(Obviously the url of the file is not as shown above, this is just for example purposes)
If I do not have the above, my report generates 100%. When I include the external pdf, however, the report fails with a "File does not begin with '%PDF-'" error. I have opened the external pdf with Notepad, and it does start with '%PDF-'
Any suggestions?