Quick addition to the below. I created a test PDF document using the EmbeddedFiles example and then parsed this document searching for the embedded file.
This worked successfully, finding the attachment. However, when I search other documents with attachments, it does not find the attachments - 'document.getDocumentCatalog().getNames()' returns null. Can attachments be added to a PDF document in more than one way? Thanks, Scott > From: [email protected] > To: [email protected] > Subject: RE: Help Extracting Attachments From A PDF > Date: Mon, 9 Mar 2009 21:31:11 +0000 > > > Hi Andreas, > > > > Thanks for the reply. > > > > I made the assumption that if PDFBox has the ability to allow you to add > attachments, then it has an API to enable you to extract attachments. > > > > Does anyone know if PDFBox does support extraction of attachments and if so > how to do it? > > > > Thanks, > > > > Scott > > > Date: Mon, 9 Mar 2009 16:29:22 +0100 > > From: [email protected] > > To: [email protected] > > Subject: Re: Help Extracting Attachments From A PDF > > > > Hi Scott, > > > > > I understand it is a busy time during the incubation period, so just a > > > quick reminder about the query below. Even if any users in the past have > > > implemented something similar, your guidance would be helpful. > > > ... > > >> > > >> I am new to PDFBox and have been working on a PDF that is encrypted and > > >> can contain zero or more attachments. > > >> > > >> > > >> I have successfully decrypted the attachment, however, I am looking for > > >> some guidance on how to extract attachments? I have debugged the > > >> application and as far as I can see the names dictionary is null. An > > >> example program or some code would be greatly appreciated. > > I'm not familiar with every pdf-feature, but I guess this one is not > > supported by pdfbox, yet. I just flew through the code and can't find a > > hint for any code concerning that feature. But perhaps someone else > > knows more about that... > > > > Andreas Lehmkühler > > _________________________________________________________________ > View your Twitter and Flickr updates from one place – Learn more! > http://clk.atdmt.com/UKM/go/137984870/direct/01/ _________________________________________________________________ View your Twitter and Flickr updates from one place – Learn more! http://clk.atdmt.com/UKM/go/137984870/direct/01/
