Copy link to clipboard
Copied
On a shared server at Newtek, I have been using cfpdfform for two years to populate PDF forms from xml files.
After moving to a CF9 server, we started getting a lot of errors during that operation.
Not always, but quite often.
Here are the details from <cfcatch>. I cannot find the error message through google at all.
Type:
Application
Message:
An exception has occured in the processing of PDF forms.
Detail:
The PDF document is not recognized as a valid PDF document.
The PDF document is indeed valid and has been used for two years successfully.
What's up? Any ideas?
Need help!
Thanks
Copy link to clipboard
Copied
I remember there were many issues with cfpdfform when CF 9 came out. Why don't you installed all the updates and hot fixes.
The source attribute of cfpdfform is either a path to a PDF file or the byte array representation of a PDF document. One way to obtain the byte array is as follows
<cfpdf action="read" source="path_to_pdf" name="pdf_doc">
<cfset pdf_byte_array = tobinary(pdf_doc)>
So you have a choice between <cfpdfform source="path_to_pdf"> and <cfpdfform source="#pdf_byte_array#">. Do these both fail?