|
-
January 7th, 2013, 03:55 PM
#8
Re: Create window form C++ function using MFC or Win32 API
Ok, you are right. Thanks Ovidiu.
Here is a bit of code, that doesn't work:
HWND hWnd = CreateWindow(szAppName, L"title", WS_OVERLAPPEDWINDOW, CW_USEDEFAULT, CW_USEDEFAULT, CW_USEDEFAULT, CW_USEDEFAULT, 0, 0, GetModuleHandle(L"vpi_win32.dll"), 0 );
vpi_printf("Window handle: %d\n", hWnd);
if(hWnd != NULL)
{
BOOL b_ShowWindowRSLT = ShowWindow(hWnd, SW_SHOWDEFAULT);
while(GetMessage(&msg, 0, 0, 0))
DispatchMessage(&msg);
vpi_printf("pass 3\n");
}
Here is CAD console output (vpi_printf):
questa_output.JPG
So, as you can constate, the execution is blocked inside of GetMessage function.
Regards,
Pavel
Tags for this Thread
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|