M
Guten Morgen zusammen.
Die Lösung habe ich:
HIMAGELIST imageList;
BUTTON_IMAGELIST buttonImageList;
HICON icon = AfxGetApp()->LoadIcon(IDI_ICON1);
imageList = ImageList_Create( 32, 32, ILC_MASK , 1, 1 );
ImageList_ReplaceIcon(imageList, -1, icon);
DestroyIcon (icon);
buttonImageList.himl = imageList;
buttonImageList.margin.left = 0;
buttonImageList.margin.top = 0;
buttonImageList.margin.right = 0;
buttonImageList.margin.bottom = 0;
buttonImageList.uAlign = BUTTON_IMAGELIST_ALIGN_CENTER;
Button_SetImageList(GetDlgItem (IDC_BUTTON1)->m_hWnd, &buttonImageList );
Funktioniert einwandfrei und ohne großer Aufwand!
P.S. Trotzdem danke für eure Ratschläge