On Apr 15, 2013 9:57 PM, <[email protected]> wrote: > > > users Digest 16 Apr 2013 02:57:37 -0000 Issue 655 > > Topics (messages 3510 through 3511) > > Re: org.apache.pdfbox.util.PDFStreamEngine processOperator INFO: unsupported/disabled operation: EI > 3510 by: Wullie > > PDFToImage not appearing as desired -- i, BMC, EMC > 3511 by: Kevin Shannon > > Administrivia: > > --------------------------------------------------------------------- > To post to the list, e-mail: [email protected] > To unsubscribe, e-mail: [email protected] > For additional commands, e-mail: [email protected] > > ---------------------------------------------------------------------- > > > Hi, > > These INFO messages are causing me issues. I'm calling PDFBox to Extract text from a PDF file, within a PHP script. The extracted text is output to the 'console' which I then read in PHP as the 'stdout' from the program. Errors I read from a similarly piped 'stderr'. > > Now unfortunately getting the return code from executing external programs in PHP is very flaky and so I cannot use an exit code of 0 from PDFBox to determine success or failure. The only way I can check whether everything was ok is to check the contents of stderr. > > However because of all these INFO messages, stderr may not be null even though everything is ok (I understand it is safe to ignore these particular INFO messages). I am forced to having to parse the stderr and use a regex to delete these info messages and see if there is then anything left which might mean error. This is not very good practice :( > > So, is there a way I can stop these INFO messages being produced in stderr? I have tried searching and found some stuff on log4j which I tried to make sense of, but I've no idea if I'm on the right track, or even how to use it! > > Please note I am using the pre-compiled jar (pdfbox-app-1.8.0.jar), and I know nothing about Java and have no way of compiling or making source code changes to Java! > > I'm sure the answer should be simple (with a log4j.xml file?) but I've no idea what to put in one, or how to get the jar to read it. > > Thanks for any help > > > > > Hi PdfBox team, > > First off, thank you for creating such a great utility! I appreciate the time and work you put into it! > > I am attaching a particular pdf where there is a field which will not display. The "Proposed Insured" pdf fields (pdf field name: InsuredFullName) at the top of page 3 & 4 displays correctly, but the same field at the top of page 5 does not. I do see the expected image if I use Adobe Reader which is why I am turning to you. I display the image on a JPanel using the PDPage.convertToImage() method, but PDFToImage displays the same output. I have attached the pdf. I am happy to attach images separately; they won't fit under 1MB. I wish I knew more about the PDF specification, so I could describe what is wrong. > > Here is the command I use and the exceptions I receive. > > C:\Users\Kevin Shannon\Downloads\DIIS Downloads>java -jar pdfbox-app-1.8.1.jar PDFToImage -startPage 4 -endPage 5 -resolution 256 -nonSeq C:\Users\Kevin Shannon\Principal\MktgIllus\Disability\DIIS\output\output1366056359491.pdf > Apr 15, 2013 3:15:25 PM org.apache.pdfbox.util.PDFStreamEngine processOperator > INFO: unsupported/disabled operation: BMC Apr 15, 2013 3:15:25 PM org.apache.pdfbox.util.PDFStreamEngine processOperator > INFO: unsupported/disabled operation: EMC Apr 15, 2013 3:15:25 PM org.apache.pdfbox.util.PDFStreamEngine processOperator > INFO: unsupported/disabled operation: i > Writing: C:\Users\Kevin Shannon\Principal\MktgIllus\Disability\DIIS\output\output13660563594914.jpg > Apr 15, 2013 3:15:27 PM org.apache.pdfbox.util.PDFStreamEngine processOperator > INFO: unsupported/disabled operation: i > Apr 15, 2013 3:15:27 PM org.apache.pdfbox.util.PDFStreamEngine processOperator > INFO: unsupported/disabled operation: BMC Apr 15, 2013 3:15:27 PM org.apache.pdfbox.util.PDFStreamEngine processOperator > INFO: unsupported/disabled operation: EMC > Writing: C:\Users\Kevin Shannon\Principal\MktgIllus\Disability\DIIS\output\output13660563594915.jpg > > What recommendations do you have for me? Is there a bug I need to report or develop a fix for? > > Thank you! > Kevin > > > -- > Kevin Shannon | @kevin_s | www.kevinjshannon.com > c: 515.991.0347 > >

