Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.lang.python > #48137

Re: Creating a Super Simple WWW Link, Copy, & Paste into Spreadsheet Program

From Neil Cerutti <neilc@norwich.edu>
Newsgroups comp.lang.python
Subject Re: Creating a Super Simple WWW Link, Copy, & Paste into Spreadsheet Program
Date 2013-06-14 12:50 +0000
Organization Norwich University
Message-ID <b20hsfFqkiqU1@mid.individual.net> (permalink)
References <34b25d59-63b8-44e7-ac10-0afc52a7d726@googlegroups.com> <CAPM-O+w3DnyHxN6==fozmFpWgXatcNABCqX3bGY8Lkar0U2JOQ@mail.gmail.com> <CALwzid=pdKz5bH027tbCfw6uFTe_aD2=ikkWbh9RnOR8uQfPUQ@mail.gmail.com> <mailman.3225.1371158741.3114.python-list@python.org>

Show all headers | View raw


On 2013-06-13, Nick Cash <nick.cash@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

Back to comp.lang.python | Previous | NextPrevious in thread | Next in thread | Find similar | Unroll thread


Thread

Creating a Super Simple WWW Link, Copy, & Paste into Spreadsheet Program buford.lumbar@gmail.com - 2013-06-13 12:28 -0700
  Re: Creating a Super Simple WWW Link, Copy, & Paste into Spreadsheet Program Joel Goldstick <joel.goldstick@gmail.com> - 2013-06-13 15:41 -0400
    Re: Creating a Super Simple WWW Link, Copy, & Paste into Spreadsheet Program buford.lumbar@gmail.com - 2013-06-13 13:18 -0700
  Re: Creating a Super Simple WWW Link, Copy, & Paste into Spreadsheet Program Dave Angel <davea@davea.name> - 2013-06-13 16:08 -0400
  Re: Creating a Super Simple WWW Link, Copy, & Paste into Spreadsheet Program Ian Kelly <ian.g.kelly@gmail.com> - 2013-06-13 14:42 -0600
  RE: Creating a Super Simple WWW Link, Copy, & Paste into Spreadsheet Program Nick Cash <nick.cash@npcinternational.com> - 2013-06-13 21:10 +0000
    Re: Creating a Super Simple WWW Link, Copy, & Paste into Spreadsheet Program Neil Cerutti <neilc@norwich.edu> - 2013-06-14 12:50 +0000
  Re: Creating a Super Simple WWW Link, Copy, & Paste into Spreadsheet Program Steven D'Aprano <steve+comp.lang.python@pearwood.info> - 2013-06-14 03:02 +0000
    Re: Creating a Super Simple WWW Link, Copy, & Paste into Spreadsheet Program buford.lumbar@gmail.com - 2013-06-14 07:03 -0700
  Re: Creating a Super Simple WWW Link, Copy, & Paste into Spreadsheet Program rusi <rustompmody@gmail.com> - 2013-06-13 21:43 -0700
  Re: Creating a Super Simple WWW Link, Copy, & Paste into Spreadsheet Program Denis McMahon <denismfmcmahon@gmail.com> - 2013-06-14 11:48 +0000
  Re: Creating a Super Simple WWW Link, Copy, & Paste into Spreadsheet Program Michael Herman <hermanmu@gmail.com> - 2013-06-14 08:02 -0700

csiph-web