Mac filename issues?
Created originally on Bitbucket by Otherfunk
Hi. I'm new to Python, and trying to convert a system I wrote in Perl.
I need to read a lot of xlsx files. Some have 's and &s in their names. These can't be renamed for production reasons. I'm using this function:-
{{{ #!python
def process_film_log(filename): from openpyxl.workbook import Workbook from openpyxl.reader.excel import load_workbook wb2 = load_workbook(filename)
}}} It is failing with this error:
File "/Library/Python/2.7/site-packages/openpyxl-1.5.2-py2.7.egg/openpyxl/reader/excel.py", line 81, in load_workbook
raise e
openpyxl.shared.exc.NamedRangeException: Invalid named range string: "'54 Earth''s Twin'!$H543:
I$559"
-- Please help? Thanks!
Attachments: 00054_Earth_s_Twin_DONE.xlsxTest__test___test.xlsx