Inhibe the ENTER and ESC KEYS ?
-
Hi, I created a project. I deleted the OK and CANCEL buttons. But when I execute my project and I press the ESC or ENTER KEYS, the project is stopped. How can I do for inhibe this KEYS? Best Regards youssef
;) I have this problem before as well. Although the button is not there, but you still have invisible OnOK() and OnCancel() function working for you! would you say it a feature or a bug? ;) what I did is to overwrite the above two functions, and say if these two buttons don't have input focus, just return. Something like this: if ( GetFocus() != GetDlgItem(IDOK)) return; else CDialog::OnOK();
-
void CMyDialog::OnOk() { } void CMyDialog::OnCancel() { }
-
Hi, I created a project. I deleted the OK and CANCEL buttons. But when I execute my project and I press the ESC or ENTER KEYS, the project is stopped. How can I do for inhibe this KEYS? Best Regards youssef
void CMyDialog::OnOk() { } void CMyDialog::OnCancel() { }
-
Hi, I created a project. I deleted the OK and CANCEL buttons. But when I execute my project and I press the ESC or ENTER KEYS, the project is stopped. How can I do for inhibe this KEYS? Best Regards youssef