the attached sample code crashes when the user does this:
- edit any cell in the second column of the grid
- click "New project" and add a new project name
- try again to edit any cell in the second column of the grid (--> crash!)
However it doesn't crash when the user does this (as soon as she opens the app):
- click "New project" and add a new project name
- edit any cell in the second column of the grid (--> no crash).
Which made me think that the crash is due to the fact that the grid-cell-editor is still visible when the grid loses the focus. So I added an event handler which hides the grid-cell-editor when the grid loses the focus (to see it working, uncomment the snippet between the triple quotes """ in my sample code). This works indeed (i.e. the grid-cell-editor is hidden). The problem is that the crash described at the begining of this email still happens.
the attached sample code crashes when the user does this:
- edit any cell in the second column of the grid
- click "New project" and add a new project name
- try again to edit any cell in the second column of the grid (--> crash!)
However it doesn't crash when the user does this (as soon as she opens the app):
- click "New project" and add a new project name
- edit any cell in the second column of the grid (--> no crash).
Which made me think that the crash is due to the fact that the grid-cell-editor is still visible when the grid loses the focus. So I added an event handler which hides the grid-cell-editor when the grid loses the focus (to see it working, uncomment the snippet between the triple quotes """ in my sample code). This works indeed (i.e. the grid-cell-editor is hidden). The problem is that the crash described at the begining of this email still happens.
Could anyone help me, please?
In similar situation i use wxCallAfter to delay grid table changes after editor is closed. Also you can force closing.