1. Convert the document (Word, Excel, PPT, etc) to PDF
2. The application (via Crystal reports) runs a report and exports it to PDF
3. AmyUni merges the PDF document and PDF Crystal report into a single document (PDF Crystal report is the cover page)
At the append step a small javascript is placed into the document
This process is working perfectly for about 85% of the documents. For the 15% that fail, they fail at the merge step. The merge begins and a 0kb file is generated and the CPU is pegged at 100% (1 full CPU is consumed). The process will remain like this indefinitelty.
If I end task on the process and disable the javascript in the merge step, the merge completes. But the problem cannot be the script itself, as it completes in 85% or more of the documents.
Due to the proprietary nature of the documents I cannot post them/send them. But I can answer any questions about them.
I know that the PDF report is in 1.3 version of Acrobat and the AmyUni converted Office document is in 1.4 version.
I can also tell you that this is running on Windows 2008 Server.
And here is the javascript that is attempting to be added during the merge step...
Code: Select all
<JavaScript EmbedScript="true">
<ScriptText><![CDATA[
var printedDate = new(Date);
var validityIntervalInHrs = 24;
var validUntilDate = new Date() ; with (validUntilDate) setHours(getHours()+validityIntervalInHrs)
var f = this.getField("Text{0}");
f.value = "Printed on "+ printedDate
]]></ScriptText>
<textField Name="Text{0}" FontName="Helvetica" FontSize="8">
<!--supported fonts are Courier,Helvetica or TimesRoman-->
<textLayout x="120" y="12" height="12" width="600" />
</textField>
</JavaScript>
Changed margins - same problem
Changed font in entire document - same problem
Converted to Office 2010 - same problem
Compressed images - same problem
Adjusted javascript location (currently in page footer) - same problem
Anyone ever seen this? Any way I can trap more information or an error? (ProcMon was no help)
Thanks in advance,
Jason