Beefy Boxes and Bandwidth Generously Provided by pair Networks
laziness, impatience, and hubris
 
PerlMonks  

Re^3: Error when trying to loop through DB and run a script

by mreece (Friar)
on Apr 03, 2007 at 19:24 UTC ( [id://608142]=note: print w/replies, xml ) Need Help??


in reply to Re^2: Error when trying to loop through DB and run a script
in thread Error when trying to loop through DB and run a script

this code appears out of order, perhaps, so i'm not sure what is going on. my guess is that the my $pdf = ... is at file scope, so setImage() is reusing the same $pdf object every time, and it probably shouldn't. consider creating a fresh PDF::API2 object each time through your while loop, and passing it explicitely to the setImage function.

Replies are listed 'Best First'.
Re^4: Error when trying to loop through DB and run a script
by ikkon (Monk) on Apr 03, 2007 at 19:50 UTC
    yep this is it, i declared pdf globaly and it worked, thanks.

Log In?
Username:
Password:

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

How do I use this?Last hourOther CB clients
Other Users?
Others perusing the Monastery: (2)
As of 2025-07-12 07:42 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found

    Notices?
    erzuuliAnonymous Monks are no longer allowed to use Super Search, due to an excessive use of this resource by robots.