Re: keyboard messages in Modal dialog box

Tech Tip: Click here to run a free scan for Windows Errors and optimize PC performance



actually question is very confusing ......
"Arman Sahakyan" <armancho_x@xxxxxxxxxx(donotspam)> wrote in message
news:E67BF873-F02A-4321-B2A7-AD7AF011D328@xxxxxxxxxxxxxxxx


"kotakmayurr@xxxxxxxxx" wrote:

I know andI have used pretranslate() but I want keyboard messages in
Modal dialog box without creating any control on the Modeless dialog
box so how i can get the keyboard message.

The question is a bit confusing... ?

You should use CWnd::PreTranslateMessage

BOOL CMyDlg::PreTranslateMessage(MSG* pMsg)
{
if (pMsg->message == WM_KEYDOWN)
{
if(pMsg->wParam == VK_ESCAPE)
{ // handle the Escape key
// do something
return TRUE;
}
}

return CDialog::PreTranslateMessage(pMsg);
}



--
======
Arman



.



Relevant Pages

  • Re: populate public property from a function
    ... confusing. ... When I assign the value of the property to a function in the control, ... So, how do I populate the arraylist as a public property, so I can use ...
    (microsoft.public.dotnet.framework.aspnet)
  • Re: Best way to make a custom control "reusable?"
    ... In the very limited situation of property procedure names or argument names ... for general functions there is no chance of "confusing" Access, ... FlexGrid control. ...
    (microsoft.public.access.formscoding)
  • Re: populate public property from a function
    ... This looks like a scoping issue. ... Very confusing. ... When I assign the value of the property to a function in the control, ... So, how do I populate the arraylist as a public property, so I can use it ...
    (microsoft.public.dotnet.framework.aspnet)
  • Re: Is daily test needed for all types of diabetes?
    ... control, is to invite disaster and the sequelae of uncontrolled ... (relating measurements to reality). ... Perhaps even obsessively numerate ... with any of the numbers can in fact make any situation more confusing. ...
    (alt.support.diabetes)
  • Re: Referencing fields from a forms underlying table
    ... Although I hate these ambiguities in Access, this gets *so* confusing that I ... is an object of type AccessField. ... RecordSource, and does not give you the control on the form, but is in some ... Textbox reference is stable, ...
    (microsoft.public.access.forms)