Beefy Boxes and Bandwidth Generously Provided by pair Networks
No such thing as a small change
 
PerlMonks  

Re: $zip->addFile not working.

by ChemBoy (Priest)
on Jun 04, 2004 at 22:50 UTC ( [id://361248]=note: print w/replies, xml ) Need Help??


in reply to $zip->addFile not working.

The error message indicates that $zip, not $fileWithPath, is your problem (that being the object you are attempting to call the method on, while $fileWithPath is the parameter you're trying to pass to the method). Without looking at the Archive::Zip documentation, I'd suggest changing your earlier code to

my $zip = Archive::Zip->new() or die "Unable to create archive: $@\n"

which should tell you what went wrong, assuming Archive::Zip::new is kind enough to set the error message when it fails.



If God had meant us to fly, he would *never* have given us the railroads.
    --Michael Flanders

Log In?
Username:
Password:

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

How do I use this?Last hourOther CB clients
Other Users?
Others admiring the Monastery: (7)
As of 2024-04-19 10:01 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found