I am creating PDFs from text files via a perl script. Some of the PDFs open without a problem. Others open and despite displaying fine, a message box appears stating:
An error exists on this page. Acrobate may not display the page correctly. Please
contact the person who created the PDF document to correct the problem.
I can click on the OK button and the page is displayed properly.
Are there any "debugging" tools out there that can help determine the error in the PDF that I am creating?
Not really. You should probably build up a library of as many different PDF tools as you can as - while none are validators - they may detect errors differently. You could also share the file to see if anyone has an idea.
I tried with an ancient version of Acrobat, and got the error "an unexpected token "T" was found". Which is true, lots of them.
I am also very suspicious of the line draw font. Does it really MacExpertEncoding? I think you have stepped outside the recommended ways of accessing a TrueType font. If you doubt this, take a look at your file with Chrome...
I tried other encodings - MacRomanEncoding, WinAnsiEncoding , ISOLatin1Encoding - and none of them rendered the PCL line draw characters properly in the pdf . I see what you mean by looking at the file in Chrome. I was only using the currenty version of Acrobat Reader. This has been my struggle all along - getting the PCL line draw characters of to appear properly in a PDF. I am using the IBM codepage437 characters. I do not know of another character set that has these characters.