Hi
I'm new to this forum,however I want to Read data from excel into python where data will be manipulated using xlrd . I'm using python 2.7 ,xlrd built fine, with out any problem. when I import xlrd and tries calling book1.xls, get the follow exceptions thrown at me :
>>> import xlrd
>>> wb = xlrd.open_workbook('Book1.xls')
Traceback (most recent call last):
File "<pyshell#12>", line 1, in <module>
wb = xlrd.open_workbook('Book1.xls')
File "C:\Python27\lib\site-packages\xlrd\__init__.py", line 425, in open_workbook
on_demand=on_demand,
File "C:\Python27\lib\site-packages\xlrd\__init__.py", line 878, in biff2_8_load
f = open(filename, open_mode)
IOError: [Errno 2] No such file or directory: 'Book1.xls
Sure there is a problem could someone point me in the right direction, will appreciate.
Thanks
This is what i got after trying out the following as in suggestion 1. listed below
XLRDError: Unsupported format, or corrupt file: Expected BOF record; found 'PK\x03\x04\x14\x00\x06\x00'
>>>
You might want to upgrade to xlrd 0.8.0 and above. . . That will solve this issue with xlsx file as the support was added In that version. Latest at the moment is 0.9.0 so even better to use that version.
Regards,
Anurag
Hi
I'm new to this forum,however I want to Read data from excel into python where data will be manipulated using xlrd . I'm using python 2.7 ,xlrd built fine, with out any problem. when I import xlrd and tries calling book1.xls, get the follow exceptions thrown at me :
>>> import xlrd
>>> wb = xlrd.open_workbook('Book1.xls')
Traceback (most recent call last):
File "<pyshell#12>", line 1, in <module>
wb = xlrd.open_workbook('Book1.xls')
File "C:\Python27\lib\site-packages\xlrd\__init__.py", line 425, in open_workbook
on_demand=on_demand,
File "C:\Python27\lib\site-packages\xlrd\__init__.py", line 878, in biff2_8_load
f = open(filename, open_mode)
IOError: [Errno 2] No such file or directory: 'Book1.xls
Sure there is a problem could someone point me in the right direction, will appreciate.
Thanks
--
You received this message because you are subscribed to the Google Groups "python-excel" group.
To unsubscribe from this group and stop receiving emails from it, send an email to python-excel...@googlegroups.com.
To post to this group, send an email to python...@googlegroups.com.
Visit this group at http://groups.google.com/group/python-excel?hl=en-GB.
For more options, visit https://groups.google.com/groups/opt_out.