g_hwnd = CreateDialog(g_hinst, (LPCTSTR)IDD_MAINWND, NULL, (DLGPROC)MainWnd);
That works fine except that when I try to hit tab in my dialog or hit enter to invoke the default button, it makes the system beep noise and does nothing. However, if I create it with the DialogBox function, like this:
DialogBox(g_hinst, (LPCTSTR)IDD_MAINWND, NULL, (DLGPROC)MainWnd);
tabbing works fine, but I don''t get a HWND handle to the window. Another interesting thing I found is that both of these functions use CreateWindowEx through a macro, so I''m also wondering how to use CreateWindowEx to create a window from a dialog resource.
Thanks in advance!
My Geekcode: "GCS d s: a14 C++$ P+(++) L+ E-- W+++$ K- w++(+++) O---- M-- Y-- PGP- t X
R- tv+ b++ DI+(+++) D- G e* h!"
Decode my geekcode!
Geekcode.com
Visit our web site: Asylum Entertainment