I've been banging my head against the wall trying to figure out the cause of the error below.
All I'm doing is running this very simple CFPDFFORM to populate a PDF form.
<cfset source = expandPath("Customer.pdf")>
<cfpdfform action="populate" source="#source#">
<cfpdfformparam name="Name" value="John Doe">
<cfpdfformparam name="Address" value="123 Test Cir">
<cfpdfformparam name="City" value="Some City">
<cfpdfformparam name="State" value="Some State">
<cfpdfformparam name="Zip" value="11111">
<cfpdfformparam name="Phone" value="123-456-7890">
</cfpdfform>
I've done a lot of searches and found very few people talking about this error. The one page that I found was ColdFusion CFPDFFORM does not populate PDF form fields. I tried the idea of going through my fonts and looking for corrupted ones. I even used a program called Fix Fonts Folder (http://fix-fonts-folder.en.softonic.com/) which was able to locate some corrupt fonts. But even then, I still get the error. So, I'm desperately looking for an answer.
Just in case, I'm running ColdFusion 10 Update 9 on Windows 7.
Thanks in advance.
I wrote a script that will parse all the font files in c:\windows\fonts and report back on the bad ones:
<cfset fontobj = createobject("java","com.adobe.fontengine.fontmanagement.FontLoader")>
<cfdirectory action="list" directory="c:\windows\fonts" name="fontdir">
<table border="1" style="border-collapse:collapse">
<tr>
<th>Font Name:</th>
<th>Error</th>
</tr>
<cfloop query="fontdir">
<cftry>
<cfset loaded = fontobj.load(createobject("java","java.net.URL").init("file:///C|/windows/fonts/#fontdir.name#"))>
<cfif arraylen(loaded) gt 0>
<cfset dummy="#loaded[1].getPlatformFontDescription()[1].toString()#" >
</cfif>
<cfcatch>
<cfif findnocase("platform",cfcatch.message)>
<tr>
<td><cfoutput>#fontdir.name#</cfoutput></td>
<td><cfoutput>#cfcatch.message#</cfoutput></td>
</tr>
</cfif>
</cfcatch>
</cftry>
</cfloop>
</table>
I had the same issue too right after the installation of CS6.0.
Platform:
Through trial and error, as stated above and a good few restarts of coldfusion I've whittled it down to the following font files that you can uninstall via font manager by going to C:\Windows\Fonts :-
Hope this helps someone. Took me a fair few hours to fix this "niggle".
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With