Re: count pages in PDF on OS 10.4 (solved)
Re: count pages in PDF on OS 10.4 (solved)
- Subject: Re: count pages in PDF on OS 10.4 (solved)
- From: Håvard Graudo <email@hidden>
- Date: Thu, 8 Jan 2009 11:45:25 +0100
Den 8. jan.. 2009 kl. 11.36 skrev Wayne Melrose:
On 8. jan.. 2009, at 11.30, Håvard Graudo wrote:
On 2009-01-08, at 00:38:39, Håvard Graudo wrote:
On 2009-01-07, at 23:49:31, Håvard Graudo wrote:
Now, does anyone have a fast and easy way to get number of
pages in PDF-files that will also work on files on a server?
Thanks Wayne, Philip and Emmanuel
I was hoping for a more generic solution if possible.
Maybe I should dive into Python?
Not quite sure what you mean by "generic".
GhostScript and xpdf are generic because they are unix tools and
so accessible by 'do shell script'.
Smile is directly accessible by AppleScript.
I usually aim for solutions that works on any Mac out of the box.
It makes scripts easier to maintain and distribute. I would think
counting pages should be a simple task for an OS that has such
tight PDF integration.
But if that is not possible, the above suggestions are all good!
Håvard
I can't remember if it was perl or python, but there was an embedded
script in the OS that I hacked at some point that was part of an
Automator action.. does that sound familiar to anyone?
Python with CoreGraphics and getNumberOfPages() does what I am after.
http://code.activestate.com/recipes/286219/
Håvard
_______________________________________________
Do not post admin requests to the list. They will be ignored.
AppleScript-Users mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
Archives: http://lists.apple.com/archives/applescript-users
This email sent to email@hidden