Hey All,
I have written two programs. Both of them have a mutex so that only one instance of each can ever be run at a time.
Program one uses ShellExecute to send information to program two. Here's a code snippet:
The problem I have is that even though program 2 is all ready running, ShellExecute tries to launch it again, which of course it can't because of the mutex.
Is there a way to do this so that it uses the program already running rather than trying to launch a new one eveytime?
Thanks so much,
Steve Q. :-)
I have written two programs. Both of them have a mutex so that only one instance of each can ever be run at a time.
Program one uses ShellExecute to send information to program two. Here's a code snippet:
Code:
if ( m_je->m_saveDCPProbePDF ) parameters = "savePDF";
else parameters = "dontSavePDF";
parameters += "*";
parameters += m_je->m_compilationPath;
parameters += "*";
parameters += m_je->m_dcpName;
ShellExecute( NULL, NULL, "DCPProbe.exe", parameters, progDir, SW_SHOWNORMAL );Is there a way to do this so that it uses the program already running rather than trying to launch a new one eveytime?
Thanks so much,
Steve Q. :-)