visual c++ - Problem displaying Icon in a button in windows xp(SP2) (MFC)! -
I had a problem displaying icons in the button with text in the MFC application. After reading many errors, The solution for this and it works great. But when I checked my application in Win XP (SP2), I was surprised by not showing me the icon. Check the code below which I used to display the icon in a symbol with a test. . Please tell me if there are any fixes for this issue .. waiting for your reply
HICON addIcon = (HICON) load image (AfxGetApp () -> m_hInstance, MAKEINTRESOURCE (IDI_ICON4), IMAGE_ICON, 0,0, LR_DEFAULTCOLOR); SendMessageA (:: GetDlgItem (m_hWnd, IDC_ADD), BM_SETIMAGE, IMAGE_ICON, (lParam) (DWORD) addIcon);
If you are using VS2008 (you should), feature pack from CMFCButton Use It has better support for bitmap buttons.
Comments
Post a Comment