AW: [wxPython-users] Troubles with GetSelectedRows()
Robin Dunn
robin at alldunn.com
Tue Sep 5 08:57:03 PDT 2006
Micha Reiser wrote:
> Thx for your help...
> Now it works fine (this). But when i will delete a row from the table it
> deletes the right values but (visual) the last row???
>
It's because of how you index your data. Since you are using (row,col)
as the key to your dictionary, when you remove all items with row=N, but
don't adjust all items with row>N to have their new row number, then the
grid will try to display the items at their old position, but since
there are fewer total rows it won't ever display the items where the row
valuer in the key is bigger than the new number of rows.
--
Robin Dunn
Software Craftsman
http://wxPython.org Java give you jitters? Relax with wxPython!
More information about the wxpython-users
mailing list