Sign up for the ITPro Today newsletter
Stay on top of the IT universe with commentary, news analysis, how-to's, and tips delivered to your inbox daily.
July 13, 2006
I have scripted Hotfix.vbs to provide more information about each hotfix than the one line '[]: KBnnnnnn - Update' provided by the SystemInfo utility.
When you run Cscript //nolog Hotfix.vbs, it provides the following information about each installed hotfix:
Number: 195Caption:CSName: JSI009Description: Security Update for Windows XP (KB918439)FixComments: UpdateHotFixID: KB918439InstalledBy: JerryInstalledOn: 6/14/2006Name:ServicePackInEffect: SP3Status:
Hotfix.vbs contains:
On Error Resume NextConst wbemFlagReturnImmediately = &h10Const wbemFlagForwardOnly = &h20strComputer = "."Set objWMIService = GetObject("winmgmts:\" & strComputer & "rootCIMV2")Set colItems = objWMIService.ExecQuery("SELECT * FROM Win32_QuickFixEngineering", "WQL", _ wbemFlagReturnImmediately + wbemFlagForwardOnly)num = 0For Each objItem In colItems num = num + 1 WScript.Echo "Number: " & num WScript.Echo "Caption: " & objItem.Caption WScript.Echo "CSName: " & objItem.CSName WScript.Echo "Description: " & objItem.Description WScript.Echo "FixComments: " & objItem.FixComments WScript.Echo "HotFixID: " & objItem.HotFixID WScript.Echo "InstalledBy: " & objItem.InstalledBy WScript.Echo "InstalledOn: " & objItem.InstalledOn WScript.Echo "Name: " & objItem.Name WScript.Echo "ServicePackInEffect: " & objItem.ServicePackInEffect WScript.Echo "Status: " & objItem.Status WScript.Echo " "Next
You May Also Like