Boa App doesn't work in Idle

I don't know if this is the place for this, since it isn`t boa's nor Idle's list. If this is the wrong list, I'll appreciate any help on getting to the right one.

I'm trying to asociate the images to a treeCtrl's imagelist, in Boa this works fine, but when I execute it in Idle it gives me an error, these are the lines I think are causing the problem:
        bmp = wxBitmap('image.bmp', wxBITMAP_TYPE_BMP)
        ImageList = wxImageList(32,32)
        Idx1 = ImageList.Add(bmp, wxNullBitmap)
and this is the error messagge
      File "D:\Desarrol\Fili\wxFrameMain.py", line 188, in __init__
        Idx1 = ImageList.Add(bmp, wxNullBitmap)
      File "C:\Desarrol\Python22\Lib\site-packages\wxPython\gdi.py", line 1065, in Add
        val = apply(gdic.wxImageList_Add,(self,) + _args, _kwargs)
    wxPyAssertionError: C++ assertion "wxAssertFailure" failed in e:\projects\wx\src\msw\bitmap.cpp(1441): invalid bitmap in wxInvertMask

Thanks.
Jorge.

Jorge Hojyo wrote:

I don't know if this is the place for this, since it isn`t boa's nor Idle's list. If this is the wrong list, I'll appreciate any help on getting to the right one.

I'm trying to asociate the images to a treeCtrl's imagelist, in Boa this works fine, but when I execute it in Idle it gives me an error, these are the lines I think are causing the problem:
       bmp = wxBitmap('image.bmp', wxBITMAP_TYPE_BMP)
       ImageList = wxImageList(32,32)
       Idx1 = ImageList.Add(bmp, wxNullBitmap)
and this is the error messagge
     File "D:\Desarrol\Fili\wxFrameMain.py", line 188, in __init__
       Idx1 = ImageList.Add(bmp, wxNullBitmap)
     File "C:\Desarrol\Python22\Lib\site-packages\wxPython\gdi.py", line 1065, in Add
       val = apply(gdic.wxImageList_Add,(self,) + _args, _kwargs)
   wxPyAssertionError: C++ assertion "wxAssertFailure" failed in e:\projects\wx\src\msw\bitmap.cpp(1441): invalid bitmap in wxInvertMask

Sorry I have no idea about this, but running wx apps in IDLE will have event loop problems anyway so it is not recommended.

···

--
Robin Dunn
Software Craftsman
http://wxPython.org Java give you jitters? Relax with wxPython!