Named range with sheet name that contains the $ throws exception when getting the cell

Aug 25, 2010 at 7:01 PM

Hi,

When a workbook contains a sheet, where the sheet name contains a $, when attempting to get the named range cell, it throws a fatal error because the cell does not exist.  I found the source of the problem as shown below, it specifically removes the $ from the range. Any ideas on a solution for this?

<definedName name="MyNamedRange">'Frank$123'!$C$10</definedName

In Excel2007.php, it has 

$extractedRange = (string)$definedName;

$extractedRange = preg_replace('/\'(\w+)\'\!/', '', $extractedRange);

$extractedRange = str_replace('$', '', $extractedRange); //  now the sheet title will not match since the $ is gone.

Coordinator
Aug 25, 2010 at 8:44 PM
This discussion has been copied to a work item. Click here to go to the work item and continue the discussion.