I'm trying to create a bootstrap application using WixStandardBootstrapperApplication. It does everything I need it to do really well except handling a restart.
I need to install a group of EXE files. Only the first one is .NET 4.5 and that requires a restart. I would delay the restart, but I can't because one of the other programs is dependent on it. I've tried using an exit code to forcereboot, but when the computer starts back up the bootstrapper gets stuck at that exit code every time, and I can't install anything else. Is there a way to apply the exit code if and only if the program has not restarted yet (or any other logical way)?
Here's what I'm doing...
<ExePackage
Id = "NetFx45Redist"
Cache = "no"
Compressed = "yes"
PerMachine = "yes"
Permanent = "yes"
Vital = "yes"
InstallCommand = "/quiet /norestart"
SourceFile = "C:\Users\visibleEP\Documents\Visual Studio 2012\Projects\Bootstrapper1\VEP Deploy\Setup Files\dotNetFx45_Full_setup.exe"
DetectCondition = "(Netfx4FullVersion="4.5.50709") AND (NOT VersionNT64 OR (Netfx4x64FullVersion="4.5.50709"))"
InstallCondition = "(VersionNT >= v6.0 OR VersionNT64 >= v6.0) AND (NOT (Netfx4FullVersion="4.5.50709" OR Netfx4x64FullVersion="4.5.50709"))">
<ExitCode Behavior = "forceReboot"/>
</ExePackage>
<ExePackage
SourceFile = "...\...\Setup Files\Encoder_en.exe"
InstallCommand = "/q"/>
<ExePackage
SourceFile = "...\...\Setup Files\vcredist_x86.exe"
InstallCommand = "/q /ACTION=Install"
RepairCommand = "/q ACTION=Repair /hideconsole" />
<ExePackage
SourceFile = "...\...\Setup Files\vcredist_x64.exe"
InstallCommand = "/q /ACTION=Install"
RepairCommand = "/q ACTION=Repair /hideconsole" />