1Simple(3)             User Contributed Perl Documentation            Simple(3)
2
3
4

NAME

6       Spreadsheet::WriteExcel::Simple - A simple single-sheet Excel document
7

SYNOPSIS

9         my $ss = Spreadsheet::WriteExcel::Simple->new;
10            $ss->write_bold_row(\@headings);
11            $ss->write_row(\@data);
12
13         print $ss->data;
14               # or
15               $ss->save("filename.xls");
16

DESCRIPTION

18       This provides an abstraction to the Spreadsheet::WriteExcel module for
19       easier creation of simple single-sheet Excel documents.
20
21       In its most basic form it provides two methods for writing data:
22       write_row and write_bold_row which write the data supplied to the next
23       row of the spreadsheet.
24
25       However, you can also use $ss->book and $ss->sheet to get at the
26       underlying workbook and worksheet from Spreadsheet::WriteExcel if you
27       wish to manipulate these directly.
28

METHODS

30   new
31         my $ss = Spreadsheet::WriteExcel::Simple->new;
32
33       Create a new single-sheet Excel document. You should not supply this a
34       filename or filehandle. The data is stored internally, and can be
35       retrieved later through the 'data' method or saved using the 'save'
36       method.
37
38   write_row / write_bold_row
39         $ss->write_bold_row(\@headings);
40         $ss->write_row(\@data);
41
42       These write the list of data into the next row of the spreadsheet.
43
44       Caveat: An internal counter is kept as to which row is being written
45       to, so if you mix these functions with direct writes of your own, these
46       functions will continue where they left off, not where you have written
47       to.
48
49   data
50         print $ss->data;
51
52       This returns the data of the spreadsheet. If you're planning to print
53       this to a web-browser, be sure to print an 'application/excel' header
54       first.
55
56   book / sheet
57         my $workbook  = $ss->book;
58         my $worksheet = $ss->sheet;
59
60       These return the underlying Spreadsheet::WriteExcel objects
61       representing the workbook and worksheet respectively. If you find
62       yourself making more that a trivial amount of use of these, you
63       probably shouldn't be using this module, but using
64       Spreadsheet::WriteExcel directly.
65
66   save
67               $ss->save("filename.xls");
68
69       Save the spreadsheet with the given filename.
70

BUGS

72       This can't yet handle dates in a sensible manner.
73

AUTHOR

75       Tony Bowden
76

BUGS and QUERIES

78       Please direct all correspondence regarding this module to:
79         bug-Spreadsheet-WriteExcel-Simple@rt.cpan.org
80

SEE ALSO

82       Spreadsheet::WriteExcel. John McNamara has done a great job with this
83       module.
84
86       Copyright (C) 2001-2005 Tony Bowden. All rights reserved.
87
88       This module is free software; you can redistribute it and/or modify it
89       under the same terms as Perl itself.
90
91
92
93perl v5.32.0                      2020-07-28                         Simple(3)
Impressum