10-21-2013, 05:30 AM
int hsb=id(3 ToolbarHwnd)
int hb hbTemp=LoadPictureFile(FavIconFilePath)
SendMessage hsb STM_SETIMAGE IMAGE_BITMAP hbTemp
hb=SendMessage(hsb STM_GETIMAGE IMAGE_BITMAP 0)
if(hb!=hbTemp) DeleteObject hbTemp ;;the control copies the bitmap if alpha
__GdiHandle- t_favicon; t_favicon.Delete; t_favicon=hb ;;will auto-delete bitmap in dtor