Hello,
I'm using CreateProcess to open a help file from my application, however my application is getting minimized and I'm having a hard time getting it back after I close the help window.
If the user presses a button in my app then I do this to show the help file:
[/code]m_pDisplay->SuspendDisplay();
PROCESS_INFORMATION pi;
CreateProcess(TEXT("peghelp.exe"), TEXT("file:help.htm#Main_Contents"), NULL, NULL, FALSE, 0, NULL, NULL, NULL, π);
WaitForSingleObject(pi.hProcess,INFINITE);
SetForegroundWindow(m_hWnd);
m_pDisplay->ResumeDisplay();
I'm using CreateProcess to open a help file from my application, however my application is getting minimized and I'm having a hard time getting it back after I close the help window.
If the user presses a button in my app then I do this to show the help file:
[/code]m_pDisplay->SuspendDisplay();
PROCESS_INFORMATION pi;
CreateProcess(TEXT("peghelp.exe"), TEXT("file:help.htm#Main_Contents"), NULL, NULL, FALSE, 0, NULL, NULL, NULL, π);
WaitForSingleObject(pi.hProcess,INFINITE);
SetForegroundWindow(m_hWnd);
m_pDisplay->ResumeDisplay();
- Code:
However, this causes the application to freeze and never stop waiting on the thread.
So can anyone tell me how I should go about this?