Windows

在 Microsoft Windows 中列出待處理更新的快捷方式

  • October 15, 2017

是否可以創建“查看更新歷史記錄”的快捷方式?

或者,您是否有列出待處理更新的腳本(powershell、vbs、cmd、…)?

試試這個 Powershell 腳本:

$update = new-object -com Microsoft.update.Session
$searcher = $update.CreateUpdateSearcher()
$pending = $searcher.Search("IsInstalled=0")
foreach($entry in $pending.Updates)
{
   Write-host "Title: " $entry.Title
   Write-host "Downloaded? " $entry.IsDownloaded
   Write-host "Description: " $entry.Description
   foreach($category in $entry.Categories)
   {
       Write-host "Category: " $category.Name
   }
   Write-host " "
}

您可能感興趣的其他對象成員可以使用以下方法查看:

$pending.Updates | member | more

引用自:https://serverfault.com/questions/135191