I'd like to create window in a UI thread?
as follows:
1. CMyThread is inherit from CWinThread
2. CMyThread::CMyThread()
{
DWORD dwExStyle = WS_EX_APPWINDOW|WS_EX_WINDOWEDGE;
DWORD dwStyle = WS_OVERLAPPEDWINDOW;
// CreateWindows for connect
m_hWnd = CreateWindowEx(dwExStyle, "ROOM", "TITLE", dwStyle, 0, 0, 10,
10, NULL, NULL, (HINSTANCE) m_hThread, NULL);
...
}
however, m_hWnd always return 0, why?
appreciate any comment and suggestions.
thank you very much!