Parsing later version PDF documents for page count

We send a large number of contracts in PDF format to an EDI application and need to know the page count in advance. We currently use a perl script to parse the PDF files for the following:
1 0 obj
<<
/Type /Pages
/Kids
[ 13 0 R
16 0 R
/Count 2
>>
endobj
This is the format of the PDF-1.3 documents. Unfortunately, the syntax is different for PDF-1.4,1.5,and 1.6.:
obj<</Metadata 21 0 R/Outlines 27 0 R/Pages 28
0R/Type/Catalog>>endobj35 0
Is it possible to parse the page count from these versions?

Actually, the fact that your parser EVER WORKED on ANY PDF files is amazing - since the fragment you posted is actually quite unusual for any version of PDF.
The correct way for you to solve this problem is to get a PDF parser (there are native Perl ones such as Text::PDF) and use that gather the information you need.

Similar Messages

  • How to create a  PDF document with page curls using Adobe  CS 4?

    My  goal is to create a  PDF document with page curls. I am using Adobe  CS 4.
    1.      The document was created in Adobe InDesign  CS 4  where the page  turn (curl) transition  was applied.
    2.      Then the document was exported to .swf.
    3.     The .swf file was imported into   Adobe Acrobat Pro  to create a PDF file with  flip page or page curl transitions.
    These are the problems.
    1.      The background is not  transparent.
    2.      Page dimensions have to be increased at least an inch in width and length so that the full page can show
    3.      The command and+   will not only increases the document's  screen size. It increases the page margins.

    PDF was never designed to support the Flash page curl effect (it didn't exist back then). Anything you try (and you've tried the standard hack) will look like a hack. Personally, I don't think the effort is worth it for an effect that's much overused.

  • Printer will no longer print PDF document--"no pages selected" although specific pages were selected?

    Brother printer will no longer print PDF document--"no pages selected" although I did specify pages.  Have reviewed and tried Adobe trouble shooting, not helpful.  Cannot print page as image.  Brother says to contact Adobe

    There may be some security issues related to the USPS PDFs.
    http://www.certified-mail-envelopes.com/signatures-usps-certified-mail-return-receipt-requested
    I can't help with the scan/print problem. You seem to have done everything I would try.
    I don't know if maybe using a registry cleaner would help.
    John Hoffman
    Conway, NH
    1D Mark IV, Rebel T5i, Pixma PRO-100, MX472

  • Why can't I open my pdf document in Pages?

    I want to open a pdf document in Pages, but is will not let me select it. How do I do this?

    You can also drag & drop from the Preview thumbnail to your Pages document.

  • PDF documents for 7.0 reporting

    Hi Gurus,
    I dont find any PDF documents for BI 7.0 reporting on Sdn.
    Please provide me the links of PDF no help links.
    Greetings.

    Any finds would be rewarded.
    [email protected]

  • I have 5 jpgs - 5 scans from A4 - and want create a 5 page pdf document, each page a jpg, what to do

    I have 5 jpgs - 5 scans from A4 - and want create a 5 page pdf document, each page a jpg, what to do? what is the easiest way?

    Mylenium gave you the exact name of the function. You could just copy that and paste it into the Google search form. You would then end up with this:
    http://tv.adobe.com/watch/learn-acrobat-9/combining-documents-into-a-single-pdf/
    Just try it out.

  • What is T-code to cancel physical inventory document for cycle count MICN?

    HI
    Please advice me what is T-code and step to cancel physical inventory document for cycle count MICN?
    Thanks

    There is no way to Cancel the Cycle count document. however you can click on 0 count so that it wont post any new entry on the cycle count.

  • How to import PDF document to Pages

    I am attempting to import a LaTex created PDF book into Pages so I can add and introduction, etc.. to the book and further refine some of the paging and print style.  This used to be possible in AppleWorks but seems to be missing in pages and now requires all editing to be done by purchasing full Adobe Acrobat which is extremely costly for a non corporate user.  I have also attempted to use several applications that purport to be able to edit PDF Doc direct but NONE of them, so far, retain the original paging information therefore rendering them USELESS for any practical use.
    Does anyone know of a widget/etc that can be added to Pages that would open the document as a Pages document while retaining ALL paging information?
    Sparkgapper

    I would dearly like to be able to fix LaTex to output a Pages document but that is waaayayyayayay beyond my capabilities and I doubt the developers of LaTex would even want to try so that is totally out of the question.  The next possibility would be to develop some kind of macro script that would do the same thing but again that is beyond my capabilities.
    I just check DataViz and they show an old MacLinks that seems to be able to convert PDF to CWK (WP) file.  I also remember one from my OLD Apple IIGS (1992) days that had the same capability but that could not be proted to the Mac and I used it quite a lot somewhat later after I started genealogical research for downloading page files.
    Thanks to all who answered and we may as well call this one unsolvable.
    Sparkgapper

  • Reducing pdf size: How can I reduce a pdf document for MAIL?

    I am having trouble getting a mail pdf attachment to be accepted by my server. I am looking for a way to reduce the digital size of the pdf (report) so that it will be a size acceptable to my server (tds).  How can that be done?  What steps should I take?

    Welcome to Apple Support Communities.
    The Quartz Filter in Finder might help.
    Open the pdf file in Preview.
    Then File, Save As, (Format PDF) checkmark the Quartz Filter, and select Reduce File Size.
    In my test example, a 4 page .pdf file of a newspaper article including lots of text and two large color photos was reduced from 573KB to 147KB.
    But do test the results first, by giving the test file a new name instead of saving 'over' the original.
    The text remained sharp, but the included photos became noticably pixelated at 100% size.
    Additional help:
    http://macintoshhowto.com/software/how-to-reduce-the-size-of-a-pdf-document-in-o s-x.html

  • Can I convert PDF documents to Pages or other formats?

    Can a PDF Document be converted to pages or other format like RTF, Text, ETC.

    Have you tried the File ➙ Export To menu in Pages for some format options?

  • Component to URL link a word/excel/pdf document inside Page

    Hello Experts,
    I would really appreciate if somebody can answer if there are any standard component or functionality available to call a network URL link to a word/excel/pdf document inside a ABOUT tab page for the definition and screenshot of How-to and functionality of the dashboard.
    I am trying to avoid creating a custom component to use SAP UI5 HTML control to initialize a OLE object call to a given URL.
    Thanks
    Arun

    Well, Word and Excel documents are binary, so you will need a Binary LOB (BLOB).
    I have recently been storing/retrieving BLOBs through ASP/ADO . . .
    BLOBs are limited to 4GB, but ADO has a limit of 2GB. Hopefully, that will not be a problem.
    If you are using ODBC, then be aware that you need to enable LOBs by setting LOB=T in the connection string. If you are using ODBC with stored procedures, then there is a bug that causes the LOBs to be truncated to 32K, which is fixed in 9.2.0.6.5. A colleague tells me that the Microsoft ODBC Driver for Oracle works with LONGs but not with LOBs.
    If you are using OleDB with stored procedures, then you'll need to set the "SPPrmsLOB" property to TRUE.
    When uploading BLOBs through ADO, you need to set the parameter size to 1 higher than the actual size, otherwise you get an error.
    When retrieving the BLOBs through stored procedures as OUT parameters, you need to set the parameter size to larger than the BLOB, otherwise it gets truncated. I do not like having to specify 2GB for a file that might only be 32K, so I prefer to return a record set via a REF CURSOR.
    Tak

  • Attaching a PDF document for a Invioce Parking thru FB60 in background

    Dear Friends,
    I am working on a requirement to build an interface for Invoice posting/Parking.
    Transaction used: FB60
    Invoice data will be stored in a staging server, same has to be read and posted in SAP. Till posting part i am clear with the requirement. Invoice data will be in a flat file which i can read and store in my Custome table.
    But customer is asking to attach a PDF document (which is a kind of supporting document not the invoice data) while doing the posting.
    My queries are:
    1. How to fetch the PDF files placed in an external staging server.
    2. How to attach those files while doing the posting/parking as job is executed in background.
    I want to use BAPI BAPI_INCOMINGINVOICE_PARK for parking the Invoice, but where to attach the PDF.
    Or can i do BDC to attach the document?
    Any info on this is highly appreciated and rewarded.
    Thanks,
    Simha

    Change in requirement..
    Hence i am closing this thread.
    Regards,
    Simha

  • Attaching a PDF document for a Invioce Parki thru FB60 in background

    Dear Friends,
    I am working on a requirement to build an interface for Invoice posting/Parking.
    Transaction used: FB60
    Invoice data will be stored in a staging server, same has to be read and posted in SAP. Till posting part i am clear with the requirement. Invoice data will be in a flat file which i can read and store in my Custome table.
    But customer is asking to attach a PDF document (which is a kind of supporting document not the invoice data) while doing the posting.
    My queries are below:
    1. How to fetch the PDF files placed in an external staging server.
    2. How to attach those files while doing the posting/parking as job is executed in background.
    I want to use BAPI BAPI_INCOMINGINVOICE_PARK for parking the Invoice, but where to attach the PDF.
    Any info on this is highly appreciated and rewarded.
    Thanks,
    Simha

    Change in requirement..
    Hence i am closing this thread.
    Regards,
    Simha

  • Storing pdf documents by pages in oracle 9i  usinf jsp

    Hi ,,,
    When pdf doc is gets uploaded it needs to be saved to the db by pages
    (Ex. if a doc. has 2 pages 2 records need to be saved to db).
    Client should be able to download several documents at once or several pages of the certain document
    how to split a pdf document in to pages by using jsp.

    please don't cross post
    http://forum.java.sun.com/thread.jspa?messageID=3874873
    Use iText.

  • How can I search a PDF document for annotations/comments

    I have a long 50+ page pdf document with many annotations and commnets.  How can I search this document to find each comment?

    Locating and Searching Comment annotations.
    From the open Comments List you can sort and filter comments.
    This is discussed in Acrobat X Pro's online Help:
    http://help.adobe.com/en_US/acrobat/pro/using/WS58a04a822e3e50102bd615109794195ff-7e42.w.h tml 
    A sorted / filtered list can be used to generate a PDF comment summary report.
    http://help.adobe.com/en_US/acrobat/pro/using/WS75E00763-F15A-43a1-85B7-51B920B1181A.w.htm l
    You could then use Find on the output summary report.
    Using Acrobat X Pro you can embed an index in the PDF.
    http://help.adobe.com/en_US/acrobat/pro/using/WSC28D4DBB-6A78-4027-9E04-F50FE411CFB9.w.htm l
    Then use the Search tool. With the Search pane open tick "Include Comments".
    Search returns have an icon at the left of each instance.
    This portion of Acrobat X Pro's online Help shows and describes these.
    The third up from the list's bottom is the Comments icon.
    http://help.adobe.com/en_US/acrobat/pro/using/WSC28D4DBB-6A78-4027-9E04-F50FE411CFB9.w.htm l 
    One of these or combinations may met your needs. 
    Be well...

Maybe you are looking for