Is there any API function for shutting down Windows while installing any pending updates?

后端 未结 1 1092
野性不改
野性不改 2021-02-20 07:52

I know the ExitWindowsEx() API function which simply shuts down Windows. But as far as I know, you cannot make Windows install any pending updates with it.

相关标签:
1条回答
  • 2021-02-20 08:39

    The best you can do is call InitiateShutdown and include the SHUTDOWN_INSTALL_UPDATES flag on Vista and higher. Windows XP does not support programmatically shutting down with updates.

    0 讨论(0)
提交回复
热议问题