[wxPython] SetIcon problem under windows

Hi-

I'm having a problem setting the icon (that thing in the upper left corner) under windows. When I run the following code under linux, the icon is set correctly but under windows I'm not having any luck. And I don't see where I'm doing things different from the demo... Anyway here's my code.

        image = wxImage(file, wxBITMAP_TYPE_JPEG)
        image = image.ConvertToBitmap()

        icon = wxEmptyIcon()
        icon.CopyFromBitmap(image)

        self.SetIcon(icon)

Anybody have a clue what might be going wrong? Thanks in advance...

Gary Sharp

···

_________________________________________________________________
Chat with friends online, try MSN Messenger: http://messenger.msn.com

Gary Sharp wrote:

Hi-

I'm having a problem setting the icon (that thing in the upper left corner) under windows. When I run the following code under linux, the icon is set correctly but under windows I'm not having any luck. And I don't see where I'm doing things different from the demo...

Is the image size 32x32?

···

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