Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...


1)How to load an icon on a button as Dynamically ?



1)How to load an icon on a button as Dynamically ?..

Answer / 106743013743

Hi Frienz,

Example:-

BOOL Ctharam::OnInitDialog()
{
CDialog::OnInitDialog();

// Below Below, to load icon on button as Dynamic
CButton *btnsample = (CButton *)GetDlgItem(IDC_BUTTON1);
btnsample->ModifyStyle(0,BS_ICON,SWP_FRAMECHANGED);
HICON hIcon = LoadIcon(AfxGetResourceHandle(),
(LPCTSTR)IDI_ICON1);
btnsample->SetIcon(hIcon);

return TRUE;

}

I hope, it might be helpful to you!!!!

By Ctharam

Is This Answer Correct ?    1 Yes 0 No

Post New Answer

More MFC Interview Questions

What MFC base classes provide support for ActiveX controls?

2 Answers   Wipro,


Which MFC function is used to display output?

9 Answers   TCS,


What is the base class for MFC

3 Answers   HCL,


What is the base class for most MFC classes?

7 Answers   CMC, Siemens,


Does the application have more than one object? If Yes, Briefly explain.

2 Answers   Soltius Infotech,


What is document-view architecture ? Give me one real time example for SDI ?

2 Answers  


What is LPCTSTR? What does LP denote it?

4 Answers  


How to find the mouse entering an image?..while entering need to display next image...

4 Answers  


What is LoadLibrary function returns?

7 Answers  


what is the use of AFX_MANAGE_STATE ?

4 Answers   HCL,


What is a critical section and how is it implemented?

2 Answers  


visual Pogramming c++ coding for create a paint application.. (Please someone help me)

2 Answers  


Categories