unable to read combo boxes in excel by xlrd package in python

Neil Cerutti neilc at norwich.edu
Fri Sep 27 11:04:22 EDT 2013


On 2013-09-27, somesh g <someshg2 at gmail.com> wrote:
> Hi..there
>
> I want to read the combo box in excel by using "xlrd" but in
> the output it is showing empty message, its not reading the
> combo box can u guys help me how to read the combo box in excel
> by "xlrd"
>
> code written like this
>
> workbook = xlrd.open_workbook('path of the file')
> worksheet = workbook.sheet_by_name('sheetname')
> TargetSystem = worksheet.cell_value(4, 2)

It depends on what kind of combo-box it is. The Excel-native
combo-box sucks (no auto-completion, no multi-select, etc.), and
so it's possible a Visual Basic widget was used instead. That
would leave the cell contents blank when read, as above.

You will need to retrieve the value from the combo-box object
directly somehow.

-- 
Neil Cerutti



More information about the Python-list mailing list