Re: Newbie: CDialog: How to get the Enterkey work the same way as TAB?

From: Doug Harrison [MVP] (dsh_at_mvps.org)
Date: 10/31/04


Date: Sun, 31 Oct 2004 11:54:09 -0600

Thomas Langer wrote:

>Hello,
>
>im a Newbie in C++, and MFC also.
>I have a SDI-Application, which opens a Dialog for entering Data. When I
>press the Enterkey the Dialog closes. But I want to get the enter-key
>act in the same way as the enter-key. Jump from edit-box to edit-box and
> on the last edit-box the data is saved and the dialog closes.
>How can i get this functionality? I have overwritten the OnOk()-Method,
>so the dialog stop closing, but the focus isn't changing.

See this KB article:

How To Use the ENTER Key from Edit Controls in a Dialog Box
http://support.microsoft.com/default.aspx?scid=kb;en-us;102589

-- 
Doug Harrison
Microsoft MVP - Visual C++


Relevant Pages

  • Appending a table from a form
    ... If I start entering data in the primary form, the PK autonumber is ... creates an entry on the 2nd table with the same number which is the ... opens a new form for the 2nd table showing the record with that ... I would open up the primary table and start entering data. ...
    (microsoft.public.access.forms)
  • RE: how to load blank record
    ... it always loads the first record. ... entering data onto thye record is ok, ... i would like to open up the dbase & go to a blank record rather go to the ... Instead the dbase opens up in record number 1. ...
    (microsoft.public.access.tablesdbdesign)
  • RE: how to load blank record
    ... it always loads the first record. ... entering data onto thye record is ok, ... i would like to open up the dbase & go to a blank record rather go to the ... Instead the dbase opens up in record number 1. ...
    (microsoft.public.access.tablesdbdesign)
  • Newbie: CDialog: How to get the Enterkey work the same way as TAB?
    ... which opens a Dialog for entering Data. ... press the Enterkey the Dialog closes. ... act in the same way as the enter-key. ... Jump from edit-box to edit-box and ...
    (microsoft.public.vc.mfc)