Shelling out to another process

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

I'm trying to use VBA to shell out to another processing
mdb that starts and quits automatically. I need this
processing mdb to complete it's procedure before returning
to the calling code. Can this be done?
 
Yes it can, you need to build a special DLL call that will wait until the process is finished
It is a small C program that, well here it is...hope you got some C knowledge..
It may be available as an API, you could call directly from the declarations section

//+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
// Waiting For Process To Finish Execution
//+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Declare long WaitForProcess ( char *progname, char *progarg
{
return (long) _spawnl( _P_WAIT, progname, progname, progarg, NULL )
}
 
Back
Top