Under Win2K, wxGrid.AutoSizeColumn() and wxGrid.AutoSizeColumns() are
causing a hard crash within Python itself (standard Windows "Application
Error" dialog). Unfortunately, it's never the first time AutoSizeColumn()
or AutoSizeColumns() are called.
Basically, I have a wxGrid representing a given table in a database. When
the user selects a different table, I refresh the Grid view to display the
selected table by adding or deleting columns and rows as necessary and
stuffing new cell values. After adding/deleting columns, I re-label each of
the Grid's columns based on the table's column names. Then I call
wxGrid.AutoSizeColumns().
After I select a certain number of tables, the app crashes - actually, the
Python interpreter crashes. With a copious number of print statements I
realized the code was crashing on the call to AutoSizeColumns. So, I
changed the code to call wxGrid.AutoSizeColumn() for each column. Same
problem.
Sometimes I can select 2 different tables before it crashes - sometimes I
can select as many as 5 different tables. Usually AutoSizeColumn() crashes
on the first column (column 0), but not always.
Any bright ideas?
- Sean Laurent
···
_______________________________________________
wxPython-users mailing list
wxPython-users@lists.sourceforge.net
http://lists.sourceforge.net/lists/listinfo/wxpython-users