Hi
Would anybody be able to give me an example of knowing in my view class when the enter key is pressed????
Thank!!!!!!
Printable View
Hi
Would anybody be able to give me an example of knowing in my view class when the enter key is pressed????
Thank!!!!!!
For example,
void CExampleView::OnKeyDown(UINT nChar, UINT nRepCnt, UINT nFlags)
{
// TODO: Add your message handler code here and/or call default
if (nChar == VK_RETURN)
{
// Do somthing
}
CView::OnKeyDown(nChar, nRepCnt, nFlags);
}
Or
void CExampleView::OnChar(UINT nChar, UINT nRepCnt, UINT nFlags)
{
// TODO: Add your message handler code here and/or call default
if (nChar == VK_RETURN)
{
// Do somthing
}
CView::OnChar(nChar, nRepCnt, nFlags);
}
Hope any help to you.