> > German,
> > > I want execute but not show the program.
> > You could always create a new desktop (or go the whole hog with a new
> > window station) for the new process. That should do the trick, if all
> > else has failed.
> Is it possible in win95? or NT only.
> _______ German Mendez _______
> A CORUNHA * GALICIA * SPAIN
In your original message you mentioned CreateProcess and the
STARTUP_INFO fields, so I assume
you want to write a program that runs another in hidden mode. I have
used code like this with
memset(&sui, 0, sizeof(sui));
sui.cb = sizeof(sui);
sui.dwFlags = STARTF_USESHOWWINDOW;
sui.wShowWindow = SW_HIDE;
BOOL bCreated = CreateProcess(...
If it doesn't work for you, perhaps you are setting up some other
argument to CreateProcess
incorrectly. I used this code to launch DOS apps that would load vxd's
to execute some control
function. It should work for win32 console apps also. One problem is
that if the dos app or
console app prints messages using printf or fprintf(stderr, the process
will hang when the app
terminates. Then GetExitCodeProcess always returns STILL_ACTIVE.