[PyKDE] Using comboboxes indexes for referencing data

Jorge Godoy godoy at ieee.org
Tue May 10 21:15:43 BST 2005


Hi,


I'm using some comboboxes in an application and I'd like to know if there's
some way to use both information it contains simultaneously:

        - text
        - index

I'd like to show the text and to make the index contain a reference to other
stuff.  It works great if my data has no holes in it, but I get the following
message if I try to insert a record with index 0 and a second record with
index 3:

        QComboBox::insertItem: (cbCodigo) Index 3 out of range

I used to work that way with wxPython and I'd really like to maintain some
logic with pyQt.

Is it possible or not?  Docs doesn't mention anything at all about that.



TIA,
-- 
Jorge Godoy      <godoy at ieee.org>





More information about the PyQt mailing list