Do you own a Debenu Quick PDF Library version 7, 8, 9, 10, 11, 12, 13 or iSEDQuickPDF license? Upgrade to Debenu Quick PDF Library 14 today!

Debenu Quick PDF Library - PDF SDK Community Forum Homepage
Forum Home Forum Home > For Users of the Library > I need help - I can help
  New Posts New Posts RSS Feed - corrupt XREF sections
  FAQ FAQ  Forum Search   Register Register  Login Login

corrupt XREF sections

 Post Reply Post Reply
Author
Message
ukobsa View Drop Down
Senior Member
Senior Member


Joined: 29 May 06
Location: Germany
Status: Offline
Points: 115
Post Options Post Options   Thanks (0) Thanks(0)   Quote ukobsa Quote  Post ReplyReply Direct Link To This Post Topic: corrupt XREF sections
    Posted: 06 Oct 06 at 5:02AM
Hi all,

sometimes I get pdfs from our customers with a corrupt xref section and cannot open it with QuickPDF. I know that it is possible to repair them with pdftk but I need a solution to do this with QuickPDF.
As I have not found anything in QuickPDF to do such a repair: has someone implemented such a functionality and would be willing to shared the code?
Or how would you implement such a repair functionality?

Thankx,
Uli
Back to Top
Ingo View Drop Down
Moderator Group
Moderator Group
Avatar

Joined: 29 Oct 05
Status: Offline
Points: 3524
Post Options Post Options   Thanks (0) Thanks(0)   Quote Ingo Quote  Post ReplyReply Direct Link To This Post Posted: 06 Oct 06 at 5:28AM
Hi Uli!

With QuickPDF you can only test if a pdf is valid or not (CheckObjects). Chicks told in an older postings how to use pdftk in such a case. It's opensource - perhaps you can detect the relevant code-parts in pdftk? Or you can implement pdftk in your solution via shell/shellexecute...

Best regards,
Ingo
Back to Top
ukobsa View Drop Down
Senior Member
Senior Member


Joined: 29 May 06
Location: Germany
Status: Offline
Points: 115
Post Options Post Options   Thanks (0) Thanks(0)   Quote ukobsa Quote  Post ReplyReply Direct Link To This Post Posted: 06 Oct 06 at 6:22AM
Hi Ingo,

I just looked for CheckObjects in source code, but this seems to do nothing really useful: it needs the document being already loaded by QuickPDF and then only decodes each object. And it doesn't returns a result of the check.
So it doesn't help to check for xref sections.
But thanks for giving this hint!

greetings,
Uli
Back to Top
marian_pascalau View Drop Down
Debenu Quick PDF Library Expert
Debenu Quick PDF Library Expert


Joined: 28 Mar 06
Location: Germany
Status: Offline
Points: 278
Post Options Post Options   Thanks (0) Thanks(0)   Quote marian_pascalau Quote  Post ReplyReply Direct Link To This Post Posted: 26 Oct 06 at 7:16AM

Hi Ulrich,

send please a test sample to me. I will check your error and propose a sollution.

Gruß, Marian

Back to Top
ukobsa View Drop Down
Senior Member
Senior Member


Joined: 29 May 06
Location: Germany
Status: Offline
Points: 115
Post Options Post Options   Thanks (0) Thanks(0)   Quote ukobsa Quote  Post ReplyReply Direct Link To This Post Posted: 26 Oct 06 at 8:24AM
Marian,

the problem with invalid XREFs mostly is caused by a wrong startxref values or invalid object positions on xref entries. What I tried to find is a way to rebuild an xref section from ground up.

greetings,
Uli
Back to Top
 Post Reply Post Reply
  Share Topic   

Forum Jump Forum Permissions View Drop Down

Forum Software by Web Wiz Forums® version 11.01
Copyright ©2001-2014 Web Wiz Ltd.

Copyright © 2017 Debenu. Debenu Quick PDF Library is a PDF SDK. All rights reserved. About — Contact — Blog — Support — Online Store