Adobe Reader cannot open PDF

Until this time we solved this old problem simply using Foxit Reader and recommended it to our partners.
But unfortunately some partners want send our PDFs to their customers who dont want use Foxit, Adobe is their company standard. Altough I saw this question already here, perhaps someone found solution since it...


Comment viewing options

Select your preferred way to display the comments and click "Save settings" to activate your changes.

PDFValidator results

PDFValidator (shareware PDF validity software) results:

0, -1, 0x00418111, "The file trailer dictionary must have an id key.", 1
0, 2, 0x80410604, "The key Metadata is required but missing.", 1
0, 75, 0x03418520, "The separator before 'endstream' must be an EOL.", 2
1, 69, 0x8041050D, "The name R7 of a graphics state dictionary resource is unknown.", 1
1, 69, 0x03418614, "A device-specific color space (DeviceRGB) without an appropriate output intent is used.", 1
1, 69, 0x83410531, "The glyph for character 1 in font 'Helvetica' is missing.", 112
1, 12, 0x80410607, "The value of the key Encoding is Difference but must be WinAnsiEncoding or MacRomanEncoding.", 3
1, 11, 0x80410604, "The key StemV is required but missing.", 3
1, 74, 0x03418614, "A device-specific color space (DeviceGray) without an appropriate output intent is used.", 1
1, 78, 0x03418520, "The separator before 'endstream' must be an EOL.", 2
2, 50, 0x00418608, "The dictionary must not contain the key 'Encoding'.", 2
2, 52, 0x03418527, "The embedded TrueType font KPSHBO+TimesNewRoman contains more than one cmap entries.", 1
2, 55, 0x03418527, "The embedded TrueType font KPSHBO+TimesNewRoman,Bold contains more than one cmap entries.", 1
2, -1, 0x00418704, "The font Helvetica must be embedded.", 38
2, -1, 0x83410612, "The document does not conform to the requested standard.", 1


This is validation against pdfa-1a

I just tried pdfvalidator, and they say the default conformance level is pdf 1.4 whereas actually it is pdfa-1a.

try the validation with the "-cl pdf1.4" switch, the results will be different.

all the pdfinclude generated files I've just validated conform to the standard pdf 1.4, whereas without the switch I get the same validation errors.


thanks I will try. As Adobat

thanks I will try.
As Adobat Reader problem disappeared a new problem emerged :)
Some printers capable to print PDF natively, does not print PDF_INC created files correctly.
Accent problems or sometimes nothing printed (and printer halted).


may be you could send us

may be you could send us your code and the pdf example.
and you could try with the updated version to see if the problems has been fixed...


Adobe Reader compatibility check

I downloaded and compiled the new version of the PDF Include and tested with Adobe products with the following results:

Adobe Reader 8.0:

Loads the PDF but displays the general error that the Page is erroneous, contact the creator of the document. Then displays parts of the file (generally the first page is empty), then a new popup window appears: Invalid object "XINV1" - INV is the name of the template I used in pdf_use_page procedure.

Adobe Professional 7.0: (we use this software for editing templates)

Couldnt find extended graphics state Named R7

then doesnt display first page of the PDF and sometimes crash in seconds. (no crash with another PDF documents)

Adobe Reader 9.0:

Doesnt display error message but shows document wrong, there are little rectangles in every line, perhaps trying display CR code?

Foxit Reader until 3.1.1

Works correctly. Later versions give similar error messages like Adobe products.

I send you the PDF file (it is a two page long invoice) if required, I can send the source code too - altough you probably cant run because it uses a lot of another depedencies.

I make the templates following way:
1. Creating PDF file from Office products (with standard AdobePDF printer driver)
2. Open in Adobe Professional 7.0 and adding fields, modifying if needed.

Important note: I think the most problems come from templates. I have no problems with simple PDF documents created without templates. This invoice is a good example because uses templates, graphics, fonts, lines, rectangles...


Adobe Reader Cannot open PDF

I am a complete newbie at this. So what follows includes blood sweat and tears.

We found that when we created a PDF template by printing a .xlsx from MS Office 2007 PDFInclude could not open it.

BUT when we used PDF Creator (free download) to print/create the template after setting all the COMPRESSION flags in PDF Creator OFF, PDFInclude worked fine.

PDF Creator download:

http://sourceforge.net/projects/pdfcreator/files/Language%20Files
/Languages%20for%200.9.3/languages-0_9_3.zip/download

I attach my code and the template. You will of course have to strip out the database field references and substitute your own and also the absolute path references. I also attach the .jpg. This code version has absolute position places (x,y coordinates). A later version reads them from the database, I hasten to explain, but that would just make your life more complicated.

We are using Adobe Reader 9 (just downloaded, all 23 MB of it).

This code is "work in progress", so please don't laugh. Get back to me if I have left out any of the necessary files.

Good luck.

Norman Baines


AttachmentSize
stattemplate.pdf7.99 KB
statementwriter1.p9.22 KB

PDF Creator works!

Hello,

altough our problem was not entirely the same as yours, but seems your recommendation works in our case. I replaced the Adobe PDF Printer printer driver to PDF Creator and Adobe Reader 9 now opens our PDF files without problem. (version 8 still shows error message but we have now a significant advance). It is very interesting that Adobe's own software does not produce correct PDF file!

Anyway, it works with compression also. EarlierI found a bug in DecompressBuffer (correctly the bug is in zlib in certain op systems) After run uncompress... in pdf_inc.p:

....
InputSize,
OUTPUT retcode).

define variable j as int.
do j=1 to (inputsize * 200):
if get-byte(tempbuffer,j) = 0 then do:
j = j - 1.
leave.
end.
end.
if retcode=0 and outputsize=0 then outputsize=j.

PROBLEM was uncompress gives sometimes 0 as outputsize (despite the uncompress done), I hacked it to find the correct output length (after realizing that tempbuffer is not empty). Searching for the first 0 byte in tempbuffer gives the correct output buffer length.

thanks!


adobe or pdf include's fault?

> It is very interesting that Adobe's own software does not produce correct PDF file!

I think that the culpable must be pdfinclude: your adobe generated file passes through pdfinclude which must interpret it badly and thus corrupt the result, whereas luckily the pdfcreator format suits him better...

I'm currently trying to rewrite this part of pdfinclude. With this new version, the way the tool generates the pdf should not matter anymore (currently, when using external pdf files as a template, pdfinclude is very nit picking about the pdf file inner format, i.e. the way it looks when you open it in a text editor)


PDF Creator template seems

PDF Creator template seems wrong. Accutes of east-european texts does not show correctly (nor the pictures in template).
I returned to Adobe Printer Driver, it is OK now. (problems solved by the correct comparision and update of old and new version of the PDF include).

Altough there are a few errors yet but currently seems Adobe Reader 9 can handle the files.

Next step is checking printers able to print PDFs natively - we have problems with it too.


Reader still does not read Landscape PDFs

the joy was too early. Certain landscape documents still cant read by Adobe Reader.

"There was error processing a page. There was problem reading this document (110)."

Foxit Reader can read this PDF without any error and displaying problem.

UPDATE: it seems it is my fault, IGNORE this.


great

Great to see your issue has been solved :) and thanks for all the information!


alonb's picture

You could try

You could try libxlsx.p.

http://www.oehive.org/project/libxlsx

It can create PDF, and MS Office, and Open Office etc. files without all these bugs, unexpected errors and current or future support issues.

All the design is done in Office and developing forms takes less then an hour compared to days with PDF Include.

Not to mention richer documents with Charts, Pivot Tables etc.


thanks but If I'm correct it

thanks but If I'm correct it works only on Windows.

I need create PDF files mainly on AIX and Linux.


alonb's picture

1. The util is 100% 4GL and

1. The util is 100% 4GL and works on UNIX/Linux and Windows, and
Progress Version 9 or higher.

2. The util can be as much as 10x times faster compared to ACTIVEX
because the files are created directly using regular OUTPUT TO, PUT
etc. file stream commands.

3. Designing forms takes less then an hour compared to days with tools
like PDF Include
because all the design is done in visual tools like Office. We
actually let our end users create and modify forms themselves.

4. The util also supports conversion to PDF, Open Office, JPEG, HTML etc.
and allows you to support multiple file formats without making any
code changes, even future file formats as they become available.

I'd be happy to show you the util and walk you through it.

You can contact me privately if you'd like alonblich@gmail.com


For Sale

Hi Alon,

Do you intend selling this Lib, as I see there is .r code only?
Would you be prepared to open it up, and let more of us work on it, as it looks really great, and exactly what I need.

Would this not also get away from the per Progress version, as I am using 10.2b and there is no .r for that, have looked at the example code, and it would suite my clients perfectly.

Thnx for all the hard work.

Jonathan Starke


alonb's picture

We sell the sources either

We sell the sources

either for an installation license or a royalty free development license.

We also give the sources for any company we do consulting for

which is what we're mostly looking for, and could really use :)


Sale of Source Code

Hi Alon,

Thanks for the prompt reply.

Could you possibly put a price to the royalty free version?

Consulting will be a bit difficult, as we are based in South Africa.

Thnx
Jonathan


alonb's picture

I would be happy to. Can we

I would be happy to.

Can we talk ?

My phone number is +972-54-2188086


alonb's picture

I'm actually a nice guy to

I'm actually a nice guy to talk to :)