This website uses cookies. By clicking Accept, you consent to the use of cookies. Click Here to learn more about how we use cookies.
Turn on suggestions
Auto-suggest helps you quickly narrow down your search results by suggesting possible matches as you type.
- Revenera Community
- :
- InstallShield
- :
- InstallShield Forum
- :
- LaunchAppAndWait Return Value - Different Question
Subscribe
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Subscribe
- Mute
- Printer Friendly Page
- Mark as New
- Subscribe
- Mute
- Permalink
- Report Inappropriate Content
‎Jan 07, 2008
03:05 PM
LaunchAppAndWait Return Value - Different Question
I am trying to launch an exe using LaunchAppAndWait which accepts .iss file as parameter. But no matter if iss is present or not, this function always return 0. Is there anyway to get the same return code which is written in the setup.log file if -f2 argument is also specified? Or, can we get some different return code if argument to this function is not valid etc.
Forget to add that I tried like this:
nResult= LaunchAppAndWait (MySetupFile, -s -f1"C:\Install.iss", LAAW_OPTION_WAIT | LAAW_OPTION_USE_CALLBACK);
And to track the return code, I use:
GetExitCodeProcess(LAAW_PROCESS_INFORMATION.hProcess, &iRetCode);
AND
NumToStr(RetCode,LAAW_PARAMETERS.nLaunchResult);
Still, no luck!
Please let me know if I am not clear. And BTW, due to some limitation I cannot use DoInstall function.
Regards
Forget to add that I tried like this:
nResult= LaunchAppAndWait (MySetupFile, -s -f1"C:\Install.iss", LAAW_OPTION_WAIT | LAAW_OPTION_USE_CALLBACK);
And to track the return code, I use:
GetExitCodeProcess(LAAW_PROCESS_INFORMATION.hProcess, &iRetCode);
AND
NumToStr(RetCode,LAAW_PARAMETERS.nLaunchResult);
Still, no luck!
Please let me know if I am not clear. And BTW, due to some limitation I cannot use DoInstall function.
Regards
(4) Replies
- Mark as New
- Subscribe
- Mute
- Permalink
- Report Inappropriate Content
‎Jan 07, 2008
05:18 PM
The help topic "Setup.exe Return Values and Run-Time Errors (InstallScript Projects)" describes the values you can expect to get back; and as a test, you might try (independent of InstallShield) a batch file that launches setup.exe and then echoes the value of %ERRORLEVEL%...
- Mark as New
- Subscribe
- Mute
- Permalink
- Report Inappropriate Content
‎Jan 08, 2008
10:14 AM
Thanks Robert for the reply, I tried it and that's also returning 0.
Probably I didn't put my questions well, I will try again:
I need to return the ResultCode from response log file from LaunchAppAndWait. Is that possible?
If not, is there any way I can do that apart from reading and parsing the setup.log file?
Pleae let me know. TIA.
Probably I didn't put my questions well, I will try again:
I need to return the ResultCode from response log file from LaunchAppAndWait. Is that possible?
If not, is there any way I can do that apart from reading and parsing the setup.log file?
Pleae let me know. TIA.
- Mark as New
- Subscribe
- Mute
- Permalink
- Report Inappropriate Content
‎Jan 08, 2008
10:26 AM
The log file is really an INI file so you could use GetProfileString to read the result.
- Mark as New
- Subscribe
- Mute
- Permalink
- Report Inappropriate Content
‎Jan 08, 2008
10:47 AM
Thanks Eric, I will give it a shot.
I still think there should be some function(s) to detect and return the values being set in the log file (not the launch codes). Don't you think so?
I still think there should be some function(s) to detect and return the values being set in the log file (not the launch codes). Don't you think so?