Performance improvement for readers that reduces overheads when setting titles in multi-worksheet workbooks, by avoiding re-iterating through all worksheet/cells whenever a sheet title is set

git-svn-id: https://phpexcel.svn.codeplex.com/svn/trunk@83603 2327b42d-5241-43d6-9e2a-de5ac946f064
This commit is contained in:
Mark Baker
2011-12-04 11:24:59 +00:00
parent c345c0e8ca
commit 5fb3ffceb0
6 changed files with 32 additions and 10 deletions
+4 -1
View File
@@ -571,7 +571,10 @@ class PHPExcel_Reader_Excel2003XML implements PHPExcel_Reader_IReader
$objPHPExcel->setActiveSheetIndex($worksheetID);
if (isset($worksheet_ss['Name'])) {
$worksheetName = self::_convertStringEncoding((string) $worksheet_ss['Name'],$this->_charSet);
$objPHPExcel->getActiveSheet()->setTitle($worksheetName);
// Use false for $updateFormulaCellReferences to prevent adjustment of worksheet references in
// formula cells... during the load, all formulae should be correct, and we're simply bringing
// the worksheet name in line with the formula, not the reverse
$objPHPExcel->getActiveSheet()->setTitle($worksheetName,false);
}
$columnID = 'A';