Skip to content

Instantly share code, notes, and snippets.

@Grimthorr
Created November 9, 2015 16:03
Show Gist options
  • Save Grimthorr/44727ea8cf5d3df11cf7 to your computer and use it in GitHub Desktop.
Save Grimthorr/44727ea8cf5d3df11cf7 to your computer and use it in GitHub Desktop.
PowerShell script to list the pending/missing Windows updates.
$UpdateSession = New-Object -ComObject Microsoft.Update.Session
$UpdateSearcher = $UpdateSession.CreateupdateSearcher()
$Updates = @($UpdateSearcher.Search("IsHidden=0 and IsInstalled=0").Updates)
$Updates | Select-Object Title
@mrbaraclough
Copy link

Thanks, this was perfect!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment