Win32 Create Process and DOS Apps

Win32 Create Process and DOS Apps

Post by Hugh Sim » Thu, 17 Oct 1996 04:00:00



I'm using CreateProcess to spawn an MS-DOS-based application from
within a Win32 program. When the DOS app terminates, the window in
which it ran remains open on the screen until the user clicks the
close button. If the user clicks on the properties button on the
toolbar, there is a check box for "close on exit" which, when checked,
causes the window to go away automatically when the DOS app
terminates. Unfortunately, the default seems to be to have this box
unchecked, forcing the user to manually dismiss the remnants of the
DOS app every time it is run unless they remember to set the
properties. I also noticed that, once the properties are set, Windows
"remembers" the fact that the DOS app should close its window on exit,
and the window will close on all future invocations.

My questions: Is there some way to force the spawned DOS app to close
its window after termination directly from the CreateProcess
parameters? If not, where are the properties for this DOS app stored,
and how can my Win32 app access them directly in order to set the
"close on exit" flag?

Thanks for your help!

 
 
 

Win32 Create Process and DOS Apps

Post by Raymond Ch » Fri, 18 Oct 1996 04:00:00




>My questions: Is there some way to force the spawned DOS app to close
>its window after termination directly from the CreateProcess
>parameters?

Simple: Have the spawned DOS app clear the screen before exiting.

--
(Note that my return address is intentionally invalid in order
to foil electronic mailing list generation software.
No soliciting.)

 
 
 

1. Win32 app communicating with DOS app

  I'm trying to find ways for a DOS program running under Windows NT to
communicate with a Win32 program on the same machine. As far as I can
tell, there's no equivalent to WOW16Call() for DOS programs, so thunking
is out. Would RPCs be suitable? And if so, where can I find the RPC SDK
for DOS? It doesn't seem to be in the current Platform SDK, though the
documentation still refers to it.

--
John Elliott

2. ATI Card question...

3. Win app to exit & run dos app w/out checking for existing apps.

4. ins0432._mp page fault error

5. How to read global DOS memory from Win95 Win32 process

6. ORA-6403: cannot allocate context area

7. Win32 Process Creation from DOS Box

8. BJC 7000 insists ink cart empty, but new cart installed ??

9. Win32 Console App call a DOS program..

10. Passing info. between DOS and Win32 Apps.

11. Can you pipe a DOS app to a win32 one?

12. How to detect Win32/Win16/DOS apps in a C program?

13. VC++ ODBC in Win32 Console App. (What am I doing wrong?)