views:

1132

answers:

2

I have an InstallShield 2009 Basic MSI project that I've modified to load the 3.5 SP1 redistributable for the .NET framework. It loads fine but as soon as it finishes it displays a prompt saying the system has to reboot, and you can either say yes and it will reboot, or no and it will stop the install.

I then went in and edited the .NET Framework 3.5 Service Pack 1 (Web Download) redistributable using InstallShield's prerequisite editor. I changed the behavior if it needs a reboot to 'Note it, fail to resume if the machine is rebooted, and reboot after the installation'. I interpreted that as meaning the reboot prompt would not be shown until the end of the install, but it still showed up in the same place.

Is there a way to suppress the prompt until the end of the install? Do I need to pick a different option from that drop-down in the pre-req editor?

Bonus question: if I need to run my install unattended, is there a way to automatically have it reboot after the entire install is finished if one is needed?

EDIT: The command switches mentioned below would probably work, but in the case of running the install unattended it will be launched from another program, and I really don't want to modify that app just for this one case. Here's a better question: is a reboot really required after installing .NET 3.5 SP1, or is it one of those things where a reboot would be good but is not absolutely needed for programs to start using the 3.5 framework?

+1  A: 

You can suppress the reboot prompt entirely by adding the following to the MSI's setup command line:

REBOOT=ReallySuppress

But then it won't prompt at the end of your complete install, as it sounds like you were hoping for; you're just stopping the prompting altogether.

As for your additional question, you can force a reboot with the following switch:

REBOOT=Force REBOOTPROMPT=Supress

Here you're telling the Windows Installer to prompt for a reboot always, and then suppressing the prompt so it just happens.

ewall
From where I can set the 'REBOOT' and 'REBOOTPROMPT' properties? I need to force restart the computer after uninstall.
Samir
In InstallShield2009 premier, basic msi project: I'v added "REBOOT=Force" "REBOOTPROMPT=Supress" properties from "Behavior and Logic"->"Property Manager".InstallShield doesn't prompt/require any restart after uninstall. But I need it for some reason.What else in addition to do besides adding the two properties ?
Samir
+2  A: 

If you type msiexec /? in the Start -> Run box, you'll get a screen with command line options for the MSI runtime, including the following:

Restart Options
    /norestart
     Do not restart after the installation is complete
    /promptrestart
     Prompts the user for restart if necessary
    /forcerestart
     Always restart the computer after installation
Amber