|
|
#1 |
|
Junior Member
Join Date: Sep 2009
Posts: 8
|
Getting the msiexec return code
Hello everyone!
I have built an installer(using NSIS) which has couple of MSIs embedded inside it. I execute these constituent MSIs by invoking "msiexec" thru ExecWait. (For example --> ExecWait 'msiexec.exe /qn /i embedded.msi TARGETDIR="$INSTDIR"' $0) Can anyone tell me a way to get the error code for the above msiexec call in my nsi script? Neither the System::Call "Kernel32::GetLastError() nor the ExecWait return value seems to do the trick!!! Any help will be appreciated! Thanks, SB |
|
|
|
|
|
#2 |
|
M.I.A.
[NSIS Dev, Mod] Join Date: Oct 2001
Location: Israel
Posts: 11,336
|
The return value of msiexec.exe is in $0.
GetLastError() is only for the current process, so it won't help you anyway. NSIS FAQ | NSIS Home Page | Donate $ "I hear and I forget. I see and I remember. I do and I understand." -- Confucius |
|
|
|
|
|
#3 |
|
Junior Member
Join Date: Sep 2009
Posts: 8
|
Thanks kichik, but that doesnt seem to work for me. I always seem to get "0" in $0 as the return value (even when msiexec.exe fails to install the msi as a result of some error thrown by the msi).
Thanks, SB. |
|
|
|
![]() |
|
|||||||
| Thread Tools | Search this Thread |
| Display Modes | |
|
|