On 2013-06-13, Nick Cash <nick.c...@npcinternational.com> wrote: >>> there is a python module that reads and writes to excel files. look >>> for that > >>More than one, actually, and which to use depends on whether >>"Excel files" means the .xls or .xlsx format. On Windows, the >>most flexible solution is going to be to just use COM to >>control the Excel >application in reading and writing the >>files. Outside of Windows, the best bet is usually to work >>>with csv files instead, as Dave suggested. > > I've had success with the xlrd and xlwt suite of modules > (http://www.python-excel.org/), using both .xls and .xlsx, on > Linux.
I use xlrd for .xlsx on Windows with Office 2007, no problems. I wouldn't call it convenient, though. It saves a coworker from doing an export which seems worth it, but using csv.DictReader is, much, much simpler. Unless there's some non-trivial need to use Excel directly I strongly recommend exporting as csv and using the csv module. -- Neil Cerutti -- http://mail.python.org/mailman/listinfo/python-list