Hi,
I'm plotting simple points with wxPyPlot. I've run into an error when I attempt to call wxPyPlot.Draw() a second time with different data points:
Traceback (most recent call last):
File "main.pyw", line 439, in OnPlot
self.pw.plot.Draw(_InitObjects(result, "%d" % self.lp.itemNumSelected))
File "wxPyPlot.py", line 621, in Draw
dc = wx.wxBufferedDC(wx.wxClientDC(self), self._Buffer)
File "C:\PYTHON22\Lib\site-packages\wxPython\gdi.py", line 999, in __init__
self.this = apply(gdic.new_wxBufferedDC,_args,_kwargs)
wxPython.wxc.wxPyAssertionError: C++ assertion "wxAssertFailure" failed in e:\projects\wx\src\msw\dcmemory.cpp(115): Bitmap is selected in another wxMemoryDC, delete the first wxMemoryDC or use SelectObject(NULL)
Is there something I didn't do that can prevent in this error? Also since I'm inexperienced with Python and wxPython, in general, can C++ assertions that occur in my program one time or another be catched with exception handling?
Timothy
Nevermind, it seems to be my stupulity that's getting in the way. After I solved other bugs, problem seems to be gone.
Timothy
Timothy wrote:
···
Hi,
I'm plotting simple points with wxPyPlot. I've run into an error when I attempt to call wxPyPlot.Draw() a second time with different data points:
Traceback (most recent call last):
File "main.pyw", line 439, in OnPlot
self.pw.plot.Draw(_InitObjects(result, "%d" % self.lp.itemNumSelected))
File "wxPyPlot.py", line 621, in Draw
dc = wx.wxBufferedDC(wx.wxClientDC(self), self._Buffer)
File "C:\PYTHON22\Lib\site-packages\wxPython\gdi.py", line 999, in __init__
self.this = apply(gdic.new_wxBufferedDC,_args,_kwargs)
wxPython.wxc.wxPyAssertionError: C++ assertion "wxAssertFailure" failed in e:\projects\wx\src\msw\dcmemory.cpp(115): Bitmap is selected in another wxMemoryDC, delete the first wxMemoryDC or use SelectObject(NULL)
Is there something I didn't do that can prevent in this error? Also since I'm inexperienced with Python and wxPython, in general, can C++ assertions that occur in my program one time or another be catched with exception handling?
Timothy
---------------------------------------------------------------------
To unsubscribe, e-mail: wxPython-users-unsubscribe@lists.wxwindows.org
For additional commands, e-mail: wxPython-users-help@lists.wxwindows.org