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

后端 未结 1 1093
野性不改
野性不改 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)
提交回复
热议问题