How can I get when the user press Enter Key in PreTranslateMessage ?
Hi,
I have a property sheet, and I want that when the user press enters it don't close, I have thought in get when the user press the enter key in the pretranslate message of the sheet and throw it away, but I do't know how to trap the enter key...
Anybody can help me ? Thanks, Bye !
Braulio
Re: How can I get when the user press Enter Key in PreTranslateMessage ?
You are right about overriding the PreTranslateMessage. What you have to do here is this. One of the parameters is the MSG structure. In the overridden function put a condition like this
if(pMsg->wParam == 13)
{
//do something here
return 1;
}
else
//return the default
I hope this solves ur problem