Beefy Boxes and Bandwidth Generously Provided by pair Networks
Just another Perl shrine
 
PerlMonks  

PDF through perl

by leelavenu (Initiate)
on Nov 06, 2006 at 11:51 UTC ( #582418=perlquestion: print w/replies, xml ) Need Help??

leelavenu has asked for the wisdom of the Perl Monks concerning the following question:

This node falls below the community's threshold of quality. You may see it by logging in.

Replies are listed 'Best First'.
Re: PDF through perl
by Joost (Canon) on Nov 06, 2006 at 12:39 UTC
Re: PDF through perl
by davorg (Chancellor) on Nov 06, 2006 at 11:56 UTC

    Without seeing your code, we can only guess at answers. Which is a waste of time for both us and you. Can you please post a _short_ program which exhibits this behaviour.

    You do have "use PDF::API2" in your code don't you?

    --
    <http://dave.org.uk>

    "The first rule of Perl club is you do not talk about Perl club."
    -- Chip Salzenberg

Re: PDF through perl
by Khen1950fx (Canon) on Nov 06, 2006 at 12:05 UTC
    Hi. Try this: use PDF::API2::Win32
      Thanks for the response. Here is the code.
      use PDF::API2::Win32; $pdf = PDF::API2::Win32->new; $fnt = $pdf->corefont('Helvetica-Bold'); $page = $pdf->page; $page->mediabox('A4'); $gfx = $page->gfx; $gfx->textlabel(200,700,$fnt,20,'Hello World !'); $pdf->saveas('/this/new/document.pdf'); $pdf->end;
      Thanks. leela

      Edited (davorg): added code tags

        Did you read the PDF::API2 documentation? If you did, then why are you doing this:
        use PDF::API2::Win32; $pdf = PDF::API2::Win32->new;
        when the docs say to do this:
        use PDF::API2; $pdf = PDF::API2->new; $fnt = $pdf->corefont('Helvetica-Bold'); $page = $pdf->page; $page->mediabox('A4'); $gfx = $page->gfx; $gfx->textlabel(200,700,$fnt,20,'Hello World !'); $pdf->saveas('/this/new/document.pdf'); $pdf->end;
        jdtoronto

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: perlquestion [id://582418]
Approved by Corion
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others cooling their heels in the Monastery: (6)
As of 2021-10-28 12:19 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?
    My first memorable Perl project was:







    Results (96 votes). Check out past polls.

    Notices?