cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
toraziyal
Level 2

installation complete exit code

I am pretty much an installshield newbie. So bear with me.

I have a customer who wants to install an applicattion via running an msi silently. This part I've got.

However, they want to be able to know when the installation is complete. They would like to be able to capture an exit code (either install success or install fail) without having to look at a log file.

How can I do this? A custom action?

I know that they are using Novell’s ZENWorks to deploy their apps. Can't zenworks capture the windows installer exit codes?

Thanks for your help.
Labels (1)
0 Kudos
(5) Replies
RobertDickau
Flexera Alumni

I don't know about ZENworks, but the Windows Installer engine executable msiexec.exe returns a value indicating if the installer was successful; please see the MSI help topic "Error Codes" for details.
0 Kudos
toraziyal
Level 2

My question was more along the lines of how can I see the error codes when I run the silent install. We need to see them as the install is running.

They don't want to view a logfile....
0 Kudos
RobertDickau
Flexera Alumni

I'm not sure about "as the install is running", but in a batch file the idea would be something like this---

msiexec.exe /i productname.msi /qb
echo %ERRORLEVEL%


---to catch the exit code, and I assume each deployment system has a way of capturing success or failure...
0 Kudos
Gvarma
Level 7

RobertDickau wrote:
I'm not sure about "as the install is running", but in a batch file the idea would be something like this---

msiexec.exe /i productname.msi /qb
echo %ERRORLEVEL%


---to catch the exit code, and I assume each deployment system has a way of capturing success or failure...


Robert,

%ERRORLEVEL% being a system variable is not a reliable way of looking for success or failure of a process, as every process that is ran at DOS level resets this var to success or failure.
0 Kudos
RobertDickau
Flexera Alumni

Quite right, I just used the example for the general timing of things, and not the specific technique...
0 Kudos