Click here to Skip to main content
15,913,310 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
GeneralRe: Painting window question Pin
PJ Arends16-Jun-03 21:20
professionalPJ Arends16-Jun-03 21:20 
GeneralRe: Painting window question Pin
Cedric Moonen16-Jun-03 21:28
Cedric Moonen16-Jun-03 21:28 
GeneralRe: Painting window question Pin
PJ Arends16-Jun-03 21:46
professionalPJ Arends16-Jun-03 21:46 
Generalquestion about dialog Pin
gucy16-Jun-03 19:41
gucy16-Jun-03 19:41 
GeneralRe: question about dialog Pin
PJ Arends16-Jun-03 20:44
professionalPJ Arends16-Jun-03 20:44 
GeneralRe: question about dialog Pin
gucy16-Jun-03 21:06
gucy16-Jun-03 21:06 
GeneralRe: question about dialog Pin
Old Gun16-Jun-03 22:15
Old Gun16-Jun-03 22:15 
QuestionVK_F10 with PreTranslateMessage not work? Pin
chen16-Jun-03 19:28
chen16-Jun-03 19:28 
Hi,

In a dialog-based application, i have a menu, a toolbar and also in order to accelerate the process i make some keyboard functions by using PreTranslateMessage. I used the Keys from F2 to F12.
The keys worked just fine except for the F10.
I note that when the key F10 is pushied the menu also show push a little at the top-left menu title, but it don't implement my expected command.

Here is the PreTrans function i used.
BOOL CEfmraDlg::PreTranslateMessage(MSG* pMsg)
{
switch(pMsg->message)
{
if(pMsg->hwnd = m_ListBox.m_hWnd)
{
case WM_KEYDOWN:
{
switch((WORD)pMsg->wParam)
{
case 'n':
case 'N':
{
m_updown = 1;
m_spinValue.SetPos(m_spinValue.GetPos()+1);
return TRUE;
}
case 'p':
case 'P':
{
if(m_secNum <= 0)
return FALSE;
else{
m_updown = 0;
m_spinValue.SetPos(m_spinValue.GetPos()-1);
return TRUE;
}
}
case VK_F2:
{
OnEfmLamp();
return TRUE;
}
case VK_F3:
{
OnEfmRead();
return TRUE;
}
case VK_F4:
{
OnEfmAbort();
return TRUE;
}
case VK_F5:
{
OnTocInfoFile();
return TRUE;
}
case VK_F6:
{
OnTocInfoCD();
return TRUE;
}
case VK_F7:
{
OnEfmCode();
return TRUE;
}
case VK_F8:
{
OnBinaryCode();
return TRUE;
}
case VK_F9:
{
OnBlock();
return TRUE;
}
case VK_F10:
{
OnSubQ();
return TRUE;
}
case VK_F11:
{
OnSubCode();
return TRUE;
}
case VK_F12:
{
OnSubRW();
return TRUE;
}
default : break;
}
break;
}
}
}
return CResizableDialog::PreTranslateMessage(pMsg);
}

How to deal eith this?

Thanks in advance!

chen
AnswerRe: VK_F10 with PreTranslateMessage not work? Pin
Eugene Pustovoyt16-Jun-03 22:14
Eugene Pustovoyt16-Jun-03 22:14 
AnswerRe: VK_F10 with PreTranslateMessage not work? Pin
Uma Mahes16-Jun-03 22:30
Uma Mahes16-Jun-03 22:30 
GeneralRe: VK_F10 with PreTranslateMessage not work? Pin
chen16-Jun-03 23:40
chen16-Jun-03 23:40 
Questionhow can i make a edit box just like the outlook's edit box? Pin
allenhu16-Jun-03 18:58
allenhu16-Jun-03 18:58 
AnswerRe: how can i make a edit box just like the outlook's edit box? Pin
David Crow17-Jun-03 3:11
David Crow17-Jun-03 3:11 
GeneralGetting the Window Class name Pin
albean16-Jun-03 18:55
albean16-Jun-03 18:55 
GeneralRe: Getting the Window Class name Pin
PJ Arends16-Jun-03 19:06
professionalPJ Arends16-Jun-03 19:06 
GeneralRe: Getting the Window Class name Pin
Uma Mahes16-Jun-03 19:15
Uma Mahes16-Jun-03 19:15 
Questionlandscape print in dialog? Pin
JockeP16-Jun-03 18:23
JockeP16-Jun-03 18:23 
AnswerRe: landscape print in dialog? Pin
Eugene Pustovoyt16-Jun-03 22:07
Eugene Pustovoyt16-Jun-03 22:07 
GeneralRe: landscape print in dialog? Pin
JockeP18-Jun-03 18:37
JockeP18-Jun-03 18:37 
GeneralRe: landscape print in dialog? Pin
Eugene Pustovoyt18-Jun-03 18:54
Eugene Pustovoyt18-Jun-03 18:54 
GeneralRe: landscape print in dialog? Pin
JockeP19-Jun-03 7:24
JockeP19-Jun-03 7:24 
GeneralColor picker Pin
chris!16-Jun-03 16:52
chris!16-Jun-03 16:52 
GeneralActiveX control---listview control 6.0 Pin
gucy16-Jun-03 16:47
gucy16-Jun-03 16:47 
Questiontabbed explorer where i can get it? Pin
david_joung16-Jun-03 15:33
david_joung16-Jun-03 15:33 
Generalwizard 98 help Pin
snipes16-Jun-03 12:45
snipes16-Jun-03 12:45 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.