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 - Dedect XFA Formulars and Portfolio Files
  FAQ FAQ  Forum Search   Register Register  Login Login

Dedect XFA Formulars and Portfolio Files

 Post Reply Post Reply
Author
Message
MP View Drop Down
Beginner
Beginner


Joined: 09 Jan 12
Status: Offline
Points: 6
Post Options Post Options   Thanks (0) Thanks(0)   Quote MP Quote  Post ReplyReply Direct Link To This Post Topic: Dedect XFA Formulars and Portfolio Files
    Posted: 09 Jan 12 at 1:53PM
We have a customer where we print some text on the first page of an PDF. The Problem is the customer has also some Portfolio PDFs and PDFs which looks like they're using XFA Formulars (which are also not supported what I've read) where the PDFs get corrupted after saving.

Is it possible to dedect if a PDF is using features not supported by QuickPdf, so that we can ignore the PDFs?

PS: When I open my Sample Portfolio file and a call GetPageText, it returnes
Zur optimalen Anzeige dieses PDF-Portfolios sollte es in Acrobat oder Adobe Reader ab Version 9 geönet werden.

which is German and means Install Acrobat Reader X for using PDF-Portfolios

Back to Top
Ingo View Drop Down
Moderator Group
Moderator Group
Avatar

Joined: 29 Oct 05
Status: Offline
Points: 3530
Post Options Post Options   Thanks (0) Thanks(0)   Quote Ingo Quote  Post ReplyReply Direct Link To This Post Posted: 09 Jan 12 at 4:16PM
Hi!
 
There is an XFA-function to count the xfa-formfields.
The other thing: Do it like you've done it...
Textextraction and searching for "Acrobat Reader X"
for example.
 
Open these files with notepad or something similar
searching for special xfa-details. If you've found some
you can check all future pdf-documents with these
specifications reading the pdf-content into a stream or
string right from harddisk.
 
Cheers and welcome here,
Ingo
 
Back to Top
AndrewC View Drop Down
Moderator Group
Moderator Group
Avatar

Joined: 08 Dec 10
Location: Geelong, Aust
Status: Offline
Points: 841
Post Options Post Options   Thanks (0) Thanks(0)   Quote AndrewC Quote  Post ReplyReply Direct Link To This Post Posted: 10 Jan 12 at 6:31AM
As Ingo has mentioned - QP.GetXFAFormFieldCount() will tell you if there are any XFA form fields in the file.

Another option is to check the Producer string -  QP.GetInformation(6);  which will return something like "Adobe LiveCycle Designer 9.0".  -  There will be different version numbers for LiveCycle but it might give you another option to detect the XFA forms based PDF's.
Back to Top
MP View Drop Down
Beginner
Beginner


Joined: 09 Jan 12
Status: Offline
Points: 6
Post Options Post Options   Thanks (0) Thanks(0)   Quote MP Quote  Post ReplyReply Direct Link To This Post Posted: 10 Jan 12 at 9:13AM
Thanks, GetInformation(6) worked for me (my version has no GetXFAFormFieldCount()).

The solution is a bit of a hack and I'm not shure if it will not result in problems in the future, will there be a method like IsFilePortfolio or IsFileSupported in future versions of quickPdf?
Back to Top
Ingo View Drop Down
Moderator Group
Moderator Group
Avatar

Joined: 29 Oct 05
Status: Offline
Points: 3530
Post Options Post Options   Thanks (0) Thanks(0)   Quote Ingo Quote  Post ReplyReply Direct Link To This Post Posted: 10 Jan 12 at 9:53AM
Hi!
 
Please upload a sample and then
i'll check how to detect it in a save way ;-)
 
Cheers, Ingo
 
Back to Top
MP View Drop Down
Beginner
Beginner


Joined: 09 Jan 12
Status: Offline
Points: 6
Post Options Post Options   Thanks (0) Thanks(0)   Quote MP Quote  Post ReplyReply Direct Link To This Post Posted: 11 Jan 12 at 11:19AM
Hi,

I have the sample documents now, but is there a way to send them to you directly? These sample documents are customer documents (even with removed Data) and I do not want to upload them visible for a public forum.
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. AboutContactBlogSupportOnline Store