Is there a version of SetFocus() that works for controls ina dialog box?
Printable View
Is there a version of SetFocus() that works for controls ina dialog box?
I believe SetFocus() does work in dialogs. You can use GetDlgItem() to get the handle to use for SetFocus().
- Sean
remember, that SetFocus() doesn't work on child controls until after the WM_CREATE or WM_INITDIALOG message has finished being processed by the parent window.
using this function while handling either of those messages will achieve nothing.. you'll have to put that code else where or try and so something smart with Tab orders.
hope this helps
U.