ID: Q196103
The information in this article applies to:
A full screen MS-DOS application or a full screen Win32 console application can be activated from a Win32 application by using the Platform SDK's APIs SetForegroundWindow() and ShowWindow().
Assuming the caption of the MS-DOS application or the Win32 console application is Test.exe, the following sample code activates the minimized MS-DOS or Win32 console application:
HWND hwndConsole = NULL;
hwndConsole = FindWindow(NULL, "Test.exe");
if(NULL != hwndConsole)
{
SetForegroundWindow(hwndConsole);
ShowWindow(hwndConsole, SW_MAXIMIZE);
}
Additional query words: SetFocus
Keywords : kbNTOS kbSDKPlatform kbWinOS95 kbWinOS98 kbWndw kbWndwProp
Version : WINDOWS:
Platform : WINDOWS
Issue type : kbhowto
Last Reviewed: November 21, 1998