and ranuse strict; use warnings; use Spreadsheet::ParseExcel::Simple; use Spreadsheet::WriteExcel::Simple; binmode STDOUT; #IN my $file = 'infile.xls'; my $xls = Spreadsheet::ParseExcel::Simple->read($file); #OUT my $ss = Spreadsheet::WriteExcel::Simple->new(); my $count; foreach my $sheet ($xls->sheets) { while ($sheet->has_data) { #Reading my @idata = $sheet->next_row; my @odata = @idata; # Here I can manipulate the data #Writing $ss->write_row(\@odata); last if $count++ > 5; } } print $ss->data;
and oufile.xls opened fine. I tried a several different versions of infile.xls with blank rows and such but it seemed to work fine.perl temp.pl >outfile.xls
--
flounder
In reply to Re: Re: Spreadsheet Parsing problem
by flounder99
in thread Spreadsheet Parsing problem
by artist
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |