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 |
What is the difference between regular dlls and extended dlls?
What interface must be supported by an ActiveX control?
How can i implement the dynamic menus in MFC plz give the code
plzz tell me what we can do and dont in tally ERP & sap business one?
1)How to change the size of a button at run time ?
General purpose classes in MFC
How to setup a timer?
Explain about MDI and CMultiDocTemplate ?
If there is more than 100 control in a window how we can change the Taborder of a controls
19)how to set Back Ground Picture to a Dialog Box in MFC ?
What is a critical section and how is it implemented?
What is CALLBACK? How it work? what is the advantage of CALLBACK, please explain with an example