in reply to Excel To Tab Delimited using Spreadsheet::ParseExcel

See also xls2csv on CPAN which outputs a CSV file (commas instead of tabs).
  • Comment on Re: Excel To Tab Delimited using Spreadsheet::ParseExcel

Replies are listed 'Best First'.
Re^2: Excel To Tab Delimited using Spreadsheet::ParseExcel
by vijax (Initiate) on Apr 26, 2010 at 10:07 UTC
    good work buddy....i am going to try this
Re^2: Excel To Tab Delimited using Spreadsheet::ParseExcel
by Anonymous Monk on Feb 25, 2015 at 20:47 UTC
    How can I retain empty cells? My report starts on the 6th column. When I use this, it removes the empty cells. I would want to have 5 tabs representing the first 5 empty columns.
      A similar script that I posted here a couple years prior to the one above preserves empty cells that occur to the left of non-empty cells. (It also handles unicode character content, in case that's relevant.) Here: xls2tsv
      use the option that is documented to stop doing that :) (hint, read the "f"riendly docs)
        I removed 3 lines from the script and it is working. The first 2 -
        $value =~ s/^\s+//; $value =~ s/\s+$//;
        , I understand, strips off spaces from beginning and end. The third line I removed
        $value = " " if $value ne "0" && !$value;
        , what does that do? I wanted to ensure I did not remove a line that 'should' be in there.