Grant Limberg
Grant Limberg

Reputation: 21363

Force shutdown in MSI installer?

I'm working on a hardware driver installer/updater. Part of the installer/updater installs an updated FPGA firmware. A requirement of the card when upgrading the FPGA firmware is that the machine must be fully powered down for the firmware upgrade to take effect. I have found the schedule and force reboot properties for MSI installers, but haven't found an analogue to force or schedule a shutdown. Is there anything in msi/windows-installer/WiX to do this, or can anyone suggest a way of accomplishing this?

Upvotes: 1

Views: 467

Answers (2)

Christopher Painter
Christopher Painter

Reputation: 55581

You could use the QuietExecute CA to call shutdown or write your own CA. Also be sure to set the /f for force option. Otherwise, be really careful that you give users the ability to supress this shutdown. Another thought might be to have your application tell the user that the software won't work until the hardware has been cold started instead of having the installer do it.

Upvotes: 2

dvallejo
dvallejo

Reputation: 1053

You could try running "Shutdown -s" to shut the machine down. Take a look at http://www.microsoft.com/resources/documentation/windows/xp/all/proddocs/en-us/shutdown.mspx?mfr=true

Upvotes: 1

Related Questions