Ctrl-W 를 눌러,
클래스 위저드에서 다이얼로그 Object를 선택 후
Messages 에서 PreTranslateMessage를 선택하여
Add Function / Edit Code 를 한 뒤 아래의 코드를 넣어준다.
BOOL ClassName::PreTranslateMessage(MSG* pMsg)
{
// TODO: Add your specialized code here and/or call the base class
if(pMsg->wParam == VK_RETURN || pMsg->wParam == VK_ESCAPE)
return TRUE;
return CDialog::PreTranslateMessage(pMsg);
}[링크 : http://lafirr.tistory.com/20]
'Programming > C Win32 MFC' 카테고리의 다른 글
| CEdit 자동스크롤 하기 (0) | 2009.06.17 |
|---|---|
| MFC Dialog 에서 CEdit 폰트 변경하기 (4) | 2009.06.15 |
| MFC 다이얼로그 프로젝트 CEdit 엔터적용 (0) | 2009.06.15 |
| MFC 프로젝트에서 RichEditCtrl 사용하기 - 왜 프로그램이 안떠? (2) | 2009.06.12 |
| indent style (0) | 2009.06.09 |