CodeGuru Home VC++ / MFC / C++ .NET / C# Visual Basic VB Forums Developer.com

Search:

Type: Posts; User: streamer

Search: Search took 0.02 seconds.

  1. Replies
    16
    Views
    30,154

    Re: Focus Problem in MFC Dialog Project

    Do you use wizard to add handlers to your dialog class?

    you should have these things:

    declaration in header file:
    afx_msg void OnKeyDown(UINT nChar, UINT nRepCnt, UINT nFlags);

    message map:...
  2. Replies
    16
    Views
    30,154

    Re: Focus Problem in MFC Dialog Project

    Look, If you have made the dialog and select it that dialog have a focus, then press some key on the keyboard, message will be dispatched to your dialog.
    You need to have OnKeyDown event handled:
    ...
  3. Replies
    16
    Views
    30,154

    Re: Focus Problem in MFC Dialog Project

    Maybe this?

    return FALSE; // return TRUE unless you set the focus to a control

    Put it back to TRUE and see what is happening
Results 1 to 3 of 3





Click Here to Expand Forum to Full Width

Featured