I am using LaunchAppAndWait to kick off a batch file using cmd.exe. It works great, but how should my code handle the call if the batch file does not exist? Is there an installshield command which can first check for the existence of "MyBatchFile.bat"? If not, how can I get InstallShield to handle a non existent file in this situation? I would like to handle the error from InstallShield rather than just getting a dos error message.
#define PROGRAM "C:Windows\\System32\\cmd.exe"
if (LaunchAppAndWait (PROGRAM, "MyBatchFile.bat", nWait) < 0) then
MessageBox ("Unable to launch "+ PROGRAM +".",SEVERE);