CreateProcess function in ActiveX

Is it possible that the CreateProcess function returns false (0)if activated from an ActiveX, just because it is activated from ActiveX ?
Who is Participating?
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.


You can create procces from ActiveX!
(Why not?)

There is an axample from MSDN:

void CAniProgress::LaunchArchive()

   char szCmdLine[260];
      MessageBox("Paths are too long",
         "Error running archive",MB_OK); return;

   strcat(szCmdLine," ");

   ZeroMemory( &si, sizeof(si) );
   si.cb = sizeof(si);  
   if( !CreateProcess( NULL,(LPSTR)    szCmdLine,NULL,NULL,
      FALSE, 0,NULL, NULL, &si,&pi ) )  
      MessageBox("Could not run archive utility",
         "Error running archive",MB_OK); return;
   DWORD ExitCode=0;
   float fProgress=10.0f;
   while(STILL_ACTIVE == ExitCode)
      if(fProgress > 100)
      Sleep(1000); //wait 1 second

   CloseHandle( pi.hProcess );



Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
System Programming

From novice to tech pro — start learning today.