Рекурсивный акроним словосочетания «PHP: Hypertext Preprocessor»
Добро пожаловать на форум PHP программистов!
За последние 24 часа нас посетили 17200 программистов и 1834 робота. Сейчас ищут 1664 программиста ...
Workbook::&addWorksheet
Вернуться к: Spreadsheet_Excel_Writer
Workbook::&addWorksheet
Workbook::&addWorksheet – Add a new worksheet to the Excel workbook.
Synopsis
require_once "Spreadsheet/Excel/Writer.php";
object reference Workbook::&addWorksheet ( string $name='' )
Add a new worksheet to the Excel workbook. If no name is given the name of the worksheet will be Sheeti with i in [1..].
Parameter
-
string $name - the optional name of the worksheet. Can not be longer than 31 characters.
Return value
returns a reference to a worksheet object on success, PEAR_Error on failure
Note
This function can not be called statically.
Example
Using &addWorksheet()
<?php
require_once 'Spreadsheet/Excel/Writer.php';
$workbook = new Spreadsheet_Excel_Writer('test.xls');
$worksheet =& $workbook->addWorksheet('My first worksheet');
if (PEAR::isError($worksheet)) {
die($worksheet->getMessage());
}
$workbook->close();
?>
Вернуться к: Spreadsheet_Excel_Writer