in reply to HTTP::Response and Spreadsheet::ParseExcel

Look at the source; it seems to me that if you feed Spreadsheet::ParseExcel a reference to a scalar it assumes you've already slurped in the file. So just pass in a ref: \$CONTENT and see if that flies.

Replies are listed 'Best First'.
Re: Re: HTTP::Response and Spreadsheet::ParseExcel
by jarp (Novice) on Oct 15, 2003 at 20:58 UTC
    Passing ParseExcel(\$CONTENT) results in an out of memory error...

    How do I read a binary and write it to file? syswrite doesn't seem to fly, using :

    open FH, "<$temp" || die "Can't open $temp : $!\n";
    syswrite (FH, $CONTENT, length $CONTENT);

    (Remember, $CONTENT is the binary xls...)
    Argggh!

      You are opening $temp for reading, not writing. Should be:

      open FH, ">$temp" or die "Can't create $temp - $!\n";
      -- vek --
        Oh geeze, don't I feel, well, blonde? Stupid? Apologies to the Monks for such an oversight. Simple things...Thanks a million for the help! J