Magnus
Fri Sep 10 08:32:23 CDT 2004
DOH!
I really feel ashamed forgetting something that trivial. But sometimes you
forget the simplest of things.
Thanks for your help.
"Sigurd Stenersen" <sigurds@utvikling.com> wrote in message
news:udUFw4ylEHA.324@TK2MSFTNGP11.phx.gbl...
> Magnus Persson wrote:
>> "Sigurd Stenersen" <sigurds@utvikling.com> wrote in message
>>> Magnus Persson wrote:
>>>> If I create controls in the OnInitDialog how can I control the tab
>>>> order of those controls?
>>>
>>> Tab order equals creation order. If you want to change the tab
>>> order and don't want to do it on creation, you might use
>>> SetWindowPos() to change the
>>> Z order (which AFAIK is the same as tab order).
>>>
>> That's what I thought but for some reason I can't move the focus
>> using the TAB key.
>>
>> I create the dialog using the API CreateDialogParam. When I get the
>> WM_INITDIALOG message I create a couple of controls (static, editbox,
>> listctrl, etc). But when the dialog is shown pressing TAB do not move
>> the focus.
>
> Did you specify the WS_TABSTOP style for the controls that are supposed to
> take focus ?
>
> Also, make sure you return the correct value from WM_INITDIALOG - you
> might
> have to initially set the focus yourself depending on what you return.
>
>
> --
>
>
> Sigurd
>
http://utvikling.com
>
>