For various reasons I need my installer to execute an MSI, so I added the following lines of code to the relevant section :
SetOverwrite on
SetOutPath "$INSTDIR\"
File "jre\java.msi"
ExecWait '$INSTDIR\java.msi When this code is executed the file is copied to the relevant directory but the msi never executes. If I change the code to this :SetOverwrite on
SetOutPath "$INSTDIR\"
File "jre\java.msi"
File "jre\java.bat"
ExecWait '$INSTDIR\java.bat' Where java.bat contains this line :java.msi it works fine, but this means I get a rather ugly command box while the MSI installer is runningEDIT : Found the solution
ExecWait will not execute the MSI file (for reason I am still unsure of) but if you use msiexec and pass the msi path as a parameter it works.
e.g.
ExecWait 'msiexec /i "$INSTDIR\java.msi" /qn"
/qn - specifies that the MSI should run silently