Futuregeek
Futuregeek

Reputation: 1980

XLSX parsing using Spreadsheet::XLSX

I have a script that will do parsing for xls like:

$parser = Spreadsheet::ParseExcel->new(
                                     CellHandler => sub {$self->handle_cell(@_) },
                                     NotSetCell  => 1
                                        );

Now I am modifying this to parse xlsx file and it seems like xlsx file will not take any parameters in new()

And handle_cell function, we get sheet_index and workbook and

$worksheet = $workbook->Worksheet($sheet_index);
 $worksheet->row_range();

I want to give parameters like CellHandler and NotSetCell to Spreadsheet::XLSX also. But I came to know that Spreadsheet::XLSX doen't take any parameters. Do we have any other Perl module that acts same as Spreadsheet::ParseExcel but for parsing xlsx?

Please help me in this. Is there any other Perl module for parsing xlsx by passing arguments to new()?

Upvotes: 0

Views: 2154

Answers (2)

EvilTeach
EvilTeach

Reputation: 28837

Yes. This is what I use.

It has an api like the parse excel module, and can deal with xlsx files. Look through the doc. There is a paragraph or two about things you can do to reduce the memory foot print.

Upvotes: 0

runrig
runrig

Reputation: 6524

There's a project started at github: Excel-Reader-XLSX. It isn't fancy but it works.

Upvotes: 2

Related Questions