Archived

This topic is now archived and is closed to further replies.

kra

Keyboard events

Recommended Posts

Hi, i''m experiencing troubles when i try to get Keyboard events in my MFC apps. I got, a class that overrides CDialog, when I override the keyboard events methods (something like onKeyPressed), those methods aren''t called (i tried a AfxMessageBox) when i press my keyboard. I''ve programmed a little bit in JAVA, and found the same problem, wich was solved by adding a TextField and setting the focus on it, is it the same problem? If so, how can i permanently set the focus on a ''hidden'' text field? thanks

Share this post


Link to post
Share on other sites
What exactly are you trying to do? Usually when you type something in a dialog it goes into one of the controls. In this case, the control (like edit box) handles the keyboard message, and your dialog doesn''t get it.

Share this post


Link to post
Share on other sites