On Mar 29, 4:27 pm, Gif <[EMAIL PROTECTED]> wrote: > I was wondering if there is a way to extract an icon from a file > (executable) and then add it in a listctrl. I also 'd like to know if > i can shorten the icon in order to fit in a listctrl item. > I've managed to get the icon from an icon file and add t as a listctrl > item but it remains 32x32. > > code: > images = ['LimeWire.ico'] > > self.il = wx.ImageList(18, 10) > self.il.Add(wx.Bitmap(images[0])) > > #This below raises an error saying that no handle was found for that > image > #self.ib = wx.IconBundle() > #self.ib.AddIconFromFile(r'LimeWire.exe', wx.BITMAP_TYPE_ANY) > > self.listView1.SetImageList(self.il, wx.IMAGE_LIST_SMALL) > self.listView1.SetItemImage(0, 0)
Please re-post to the wxPython user's group: http://wxpython.org/maillist.php I'm pretty sure they know how to do this. Mike -- http://mail.python.org/mailman/listinfo/python-list