jmcnamara / excel-reader-xlsx

Read data from an Excel 2007+/XLSX format file.

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Note:

This project is effectively abandoned. I don't have the required time
to finish it off and get it to CPAN quality.

It is functional and if it meets your requirements then please use it but
it is unlikely that it will ever be extended.

As an alternative have a look at the Spreadsheet::ParseXLSX
module which is on CPAN.

http://search.cpan.org/~doy/Spreadsheet-ParseXLSX/lib/Spreadsheet/ParseXLSX.pm

NAME

    Excel::Reader::XLSX - Read data from an Excel 2007+/XLSX format file.

DESCRIPTION

    Excel::Reader::XLSX is a fast and lightweight parser for Excel 2007+
    XLSX files.

    The XLSX format is the Office Open XML (OOXML) format used by Excel 2007
    and later.

SYNOPSIS

    A simple Excel XLSX file reader based on Excel::Reader::XLSX:

    use strict;
    use warnings;
    use Excel::Reader::XLSX;

    my $reader   = Excel::Reader::XLSX->new();
    my $workbook = $reader->read_file( 'Book1.xlsx' );

    if ( !defined $workbook ) {
        die $reader->error(), "\n";
    }

    for my $worksheet ( $workbook->worksheets() ) {

        my $sheetname = $worksheet->name();

        print "Sheet = $sheetname\n";

        while ( my $row = $worksheet->next_row() ) {

            while ( my $cell = $row->next_cell() ) {

                my $row   = $cell->row();
                my $col   = $cell->col();
                my $value = $cell->value();

                print "  Cell ($row, $col) = $value\n";
            }
        }
    }


INSTALLATION

    Use the standard Unix style installation. Unzip and untar the module:

        tar -zxvf Excel-Reader-XLSX-0.xx.tar.gz

    The module can be installed using the standard Perl procedure:

        perl Makefile.PL
        make
        make test
        make install    # As sudo/root

AUTHOR

    John McNamara (jmcnamara@cpan.org)

About

Read data from an Excel 2007+/XLSX format file.


Languages

Language:Perl 100.0%