Click to See Complete Forum and Search --> : Setting active CEdit on entering a Property page


Richard Smith
April 1st, 1999, 10:55 AM
When the user returns to a particular property page, I need to to have focus on the same CEdit that had control when the page was exited. It is easy to get the active Ctrl at OnKillActive() time. But using GotoDlgCtrl() at OnSetActive() time does not appear to work. The first CEdit always has focus.

Mike
April 1st, 1999, 11:28 AM
I haven't used OnSetActive() in a while but, does it call a method from the inherited CDialog (i.e. CDialog::OneSetActive())?


If so, make sure your code follows this call otherwise it will reset the according to the tab settings.


Just a guess...

Richard Smith
April 1st, 1999, 11:48 AM
As you suspected, OnSetActive() calls CPropertyPage::OnSetActive().

My GotoDlgCtrl() follows this, so that is not the solution.


My guess is that a later action (DDE?) is doing me in.