Bugfix: Workitem 14086 - Named range with sheet name that contains the $ throws exception when getting the cell

git-svn-id: https://phpexcel.svn.codeplex.com/svn/trunk@61245 2327b42d-5241-43d6-9e2a-de5ac946f064
This commit is contained in:
Mark Baker 2010-09-20 15:05:54 +00:00
parent 06535cc296
commit f93fde9b38

View File

@ -1345,7 +1345,11 @@ class PHPExcel_Reader_Excel2007 implements PHPExcel_Reader_IReader
// Extract range
$extractedRange = (string)$definedName;
$extractedRange = preg_replace('/\'(\w+)\'\!/', '', $extractedRange);
$extractedRange = str_replace('$', '', $extractedRange);
if (($spos = strpos($extractedRange,'!')) !== false) {
$extractedRange = substr($extractedRange,0,$spos).str_replace('$', '', substr($extractedRange,$spos));
} else {
$extractedRange = str_replace('$', '', $extractedRange);
}
// Valid range?
if (stripos((string)$definedName, '#REF!') !== false || $extractedRange == '') {