
Shell Bug.. 0 returned when EXE is successfully launched
Yes, the return value is Long.
I wrote a sample program for test in the office, and all worked fine on a
"dummy" EXE program, (a valid number was returned). However, out in the
field where the project is, the EXE that has to be interfaced to starts up,
but the return value is 0. I fundamentally pasted the code in. Thanks for
your reply.
Quote:
> > I need the valid process number for some API calls. However,
> when I launch
> > the EXE, (successfully) all that is returned is 0.
> > Does anyone know how to find out what causes the error?
> Use GetLastError to retrieve the last error generated. If you
> do this immediately
> after CreateProcess returns zero, this should reflect why
> CreateProcess did not
> succeed.