Click here to Skip to main content
15,878,852 members
Please Sign up or sign in to vote.
5.00/5 (3 votes)
See more:
C++
CButton* pBtn= (CButton*)GetDlgItem(IDC_BUTTON1);
   pBtn->ModifyStyle( 0, BS_ICON );
   HICON hIcn= (HICON)LoadImage(
        AfxGetApp()->m_hInstance,
  MAKEINTRESOURCE(IDI_ICON1),
        IMAGE_ICON,
        63,66, // use actual size
        LR_DEFAULTCOLOR
    );

    pBtn->SetIcon( hIcn );
Posted
Updated 19-Apr-13 22:00pm
v3
Comments
CPallini 20-Apr-13 4:14am    
And the question is?

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900