sjmachin at lexicon.net
Mon Aug 4 12:19:27 CEST 2008
Yeats <w.b.yeats <at> uol.com.br> writes:
> Years ago i use xlrd to read data from
> excel and now I need again, but i get strange result. The code is:
> from xlrd import *
> Planilha =
> open_workbook('C:\\Resultados.xls')Resultados =
> Planilha.sheet_by_name('Resultados')c =
> (Resultados.cell_value(2,2))print c
So that's cell_value(rowx=2, colx=2). colx=2 translates to column C on your
screen. rowx=2 translates to row 3 on your screen. What does cell C3 show on
your screen when you use Excel?
> and the result is: 0, but the value in
> cell is : VERDADEIRO
And in what cell is VERDADEIRO on your screen?
By the way, it's usually a good idea to say what version of Windows, Python and
xlrd that you are using. It's also usually a good idea to check the README file
for a third-party module or package to find out where it is suggested that you
ask questions ... the answer is rarely comp.lang.python.
More information about the Python-list