swftools-common
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Swftools-common] How do I know how many pages a PDF has?


From: Chris Pugh
Subject: Re: [Swftools-common] How do I know how many pages a PDF has?
Date: Sat, 3 Apr 2010 01:16:11 +0100

Apologies Sam.  Meant to add this bit to my original list post:

Id you have xpdf properly installed, there you should have access to
the 'pdfinfo' command.
This will do what you need. e,g,

    pdfinfo -meta sams.pdf | grep "Pages" | cut -d" " -f11

( looks like the xpdf meta output is padded with spaces. )

One more script line, and you have your automatic page conversion sorted! ;o)

HTH.

Regards,


Chris.

On 2 April 2010 23:05, Sam Kong <address@hidden> wrote:
> Hi Chris,
>
> You're right.
> It'd work but takes a lot of time.
> I'll search for an alternative tool for that.
>
> Thanks.
>
> ----------------------
> Sam Kong
> Design Premise
> On Fri, Apr 2, 2010 at 1:02 PM, Chris Pugh <address@hidden> wrote:
>>
>> Did you ever notice what happens if you issue the pdf2swf command on
>> it's own Sam?  With or without '-s help'?  Did we bother to take a
>> peek at all?   ;o)
>>
>> With Bash under linux, :how's about,
>>
>>   pdf2swf -I  sams.pdf | tail -n  1 |  cut -d" " -f1
>>
>> You could do something similar with Pash ( or Powershell ), if you
>> happen to be under Windows.
>>
>> The only snag, is that as dfar as I am aware, the whole pdf has to be
>> processed just to get
>> at the last page..  Maybe you should try using an alternatuve tool if
>> you wish to simply grab
>> information about the pdf?
>>
>> HTH
>>
>> Regards,
>>
>>
>> Chris.
>>
>> On 2 April 2010 18:19, Sam Kong <address@hidden> wrote:
>> > Hi,
>> >
>> > I am trying to automate converting a pdf to swf page by page.
>> > How do I know the total pages of a pdf?
>> > ----------------------
>> > Sam Kong
>> > Design Premise
>
>




reply via email to

[Prev in Thread] Current Thread [Next in Thread]