+ Reply to Thread
Results 1 to 2 of 2

PDF Page Count

  1. #1
    Registered User
    Join Date
    12-02-2014
    Location
    California
    MS-Off Ver
    2010
    Posts
    6

    PDF Page Count

    I'm looking to find the number of pages within a PDF file. I've tried 3 methods, found in various forums, which get stuck at some stage in the code. In all methods I'd like to open the PDF file as .txt and search for the string /pages. A couple characters/positions after this string contains the number of pages. See below:

    Opening the PDF in binary code does not contain the same text/information as a .txt. Is there a way to use 'Open' function to a .txt file?
    Formula: copy to clipboard
    Please Login or Register  to view this content.


    The next method was to open the file shell command. I can open the PDF as .txt however not aware of a method to activate that file and extract the data I
    Formula: copy to clipboard
    Please Login or Register  to view this content.


    Finally I want to use the 'Name' function to rename the PDF .txt, open the new file and extract that way. However, in doing so I get an "invalid procedure" at the 'Name' function line.
    Formula: copy to clipboard
    Please Login or Register  to view this content.


    Similarly I could copy or convert the pdf file to a .txt since I still want to maintain the original pdf file.

    Am I on the right path with any of these?

  2. #2
    Forum Guru karedog's Avatar
    Join Date
    10-03-2014
    Location
    Indonesia
    MS-Off Ver
    2003
    Posts
    2,971

    Re: PDF Page Count

    UDF :
    Please Login or Register  to view this content.
    Example usage :
    Please Login or Register  to view this content.
    1. I care dog
    2. I am a loop maniac
    3. Forum rules link : Click here
    3.33. Don't forget to mark the thread as solved, this is important

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. Pdf page count
    By dark91zc in forum Excel Programming / VBA / Macros
    Replies: 3
    Last Post: 12-02-2013, 07:37 PM
  2. Automatically adding a blank page at the end of sheets with page count odd
    By NewDawn999 in forum Excel Programming / VBA / Macros
    Replies: 8
    Last Post: 08-15-2013, 02:33 PM
  3. [SOLVED] incremental Count Page count
    By mohan.r1980 in forum Excel General
    Replies: 3
    Last Post: 05-16-2012, 03:58 AM
  4. Page Count of pdf
    By mohan.r1980 in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 04-05-2012, 07:57 PM
  5. Replies: 2
    Last Post: 08-04-2011, 06:42 AM
  6. Page Count
    By pkferret in forum Excel General
    Replies: 3
    Last Post: 04-12-2006, 10:19 AM
  7. Inserting page number & page count in cells
    By Jeff in forum Excel General
    Replies: 0
    Last Post: 05-02-2005, 04:06 PM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1