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) Enable or disable a Cancel button at run time?



1) Enable or disable a Cancel button at run time?..

Answer / 106743013743

Hi,

Example:-

BOOL Ctharam::OnInitDialog()
{
CDialog::OnInitDialog();
// Below Code, To Enable or Disable a button as
runtime
CButton *pLogin1 = (CButton*)GetDlgItem(IDCANCEL);
pLogin1->SetWindowTextW(L"Reset");
pLogin1->EnableWindow(FALSE);

return TRUE;
}

Note:- pLogin1->EnableWindow(TRUE); // to enable a Cancel
button


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

Is This Answer Correct ?    1 Yes 2 No

Post New Answer

More MFC Interview Questions

1)How to change a text of a button in runtime?

2 Answers  


What is the difference between OnInitialUpdate and OnUpdate?

5 Answers  


How to create a Modeless Dialog?

5 Answers  


How do you change the properties for a tree view control that is part of the CTreeView class?

1 Answers  


How can i change the color of a dropdowncombobox elements

2 Answers  


what message is sent to an application when the user presses the primary button?

0 Answers   University Exams,


What types of threads are supported by MFC framework?

2 Answers  


Which CPrintInfo member variable must be set for multiple page printouts?

1 Answers  


what is the difference between compiling and building?

1 Answers  


Explain Doc/View architecture

6 Answers   Huawei,


List out the basic features of MFC.

4 Answers   Mphasis,


Tell me the different controls in MFC ?

5 Answers  


Categories