Display windows hotfixes
By nater

On Error Resume Next

Const wbemFlagReturnImmediately = &h10
Const wbemFlagForwardOnly = &h20
Set objIExplorer = CreateObject("InternetExplorer.Application")
objIExplorer.ToolBar = 1
objIExplorer.StatusBar = 0
objIExplorer.Width = 850
objIExplorer.Height = 600
objIExplorer.Left = 5
objIExplorer.Top = 5
objIExplorer.Visible = 1

objIExplorer.Navigate "about:blank"
Set objDocument = objIExplorer.Document
objDocument.Open
objDocument.Writeln "<body bgcolor='white'>"
objDocument.Writeln "<html><head><title>Ladeee doo dadoo</title></head>"
objDocument.Writeln "<br>"
objDocument.Writeln "Important Notes: If there are no discriptions, dates or additional information"
objDocument.Writeln "<br>"
objDocument.Writeln "It simply can mean that the hotfix shipped with the original install cd.. therefor no information was recorded for this."
objDocument.Writeln "<br>"
objDocument.Writeln "<br>"
objDocument.Writeln "<font color=#FF0000>scroll to near the end and you will see the user applied hotfixes</font>"
objDocument.Writeln "<br>"
objDocument.Writeln "<br>"
objDocument.Writeln "<br>"
objDocument.Writeln "<br>"

objDocument.Writeln "<table border='1' width='100%' id='table1'>"




strComputer = "."



Set objWMIService = GetObject("winmgmts:" & strComputer & "\root\CIMV2")
Set colItems = objWMIService.ExecQuery("SELECT * FROM Win32_QuickFixEngineering", "WQL", _
wbemFlagReturnImmediately + wbemFlagForwardOnly)

For Each objItem In colItems
objDocument.Writeln "<tr><b><td width='100%'>"
objDocument.Writeln "Caption: " & objItem.Caption
objDocument.Writeln "<br>"
objDocument.Writeln "CSName: " & objItem.CSName
objDocument.Writeln "<br>"
objDocument.Writeln "Description: " & objItem.Description
objDocument.Writeln "<br>"
objDocument.Writeln "FixComments: " & objItem.FixComments
objDocument.Writeln "<br>"
objDocument.Writeln "HotFixID: " & objItem.HotFixID
objDocument.Writeln "<br>"
' objDocument.Writeln "InstallDate: " & WMIDateStringToDate(objItem.InstallDate)
objDocument.Writeln "InstalledBy: " & objItem.InstalledBy
objDocument.Writeln "<br>"
objDocument.Writeln "InstalledOn: " & objItem.InstalledOn
objDocument.Writeln "<br>"
objDocument.Writeln "Name: " & objItem.Name
objDocument.Writeln "<br>"
objDocument.Writeln "ServicePackInEffect: " & objItem.ServicePackInEffect
objDocument.Writeln "<br>"
objDocument.Writeln "Status: " & objItem.Status
objDocument.Writeln "<br>"
objDocument.Writeln "<br>"

objDocument.Writeln "</tr><p>"

Next



Function WMIDateStringToDate(dtmDate)
objDocument.Writeln dtm:
WMIDateStringToDate = CDate(Mid(dtmDate, 5, 2) & "/" & _
Mid(dtmDate, 7, 2) & "/" & Left(dtmDate, 4) _
& " " & Mid (dtmDate, 9, 2) & ":" & Mid(dtmDate, 11, 2) & ":" & Mid(dtmDate,13, 2))
End Function



objdocument.Close

set objFSO = Nothing

Rating:


0/5 based on 0 votes. The median rating is 0.

Submitted: 11/19/10 (Edited 11/19/10)

Description: This vbscript will display windows hotfixes that were installed on a computer. It also will display the date and user if the hotfix was user applied and not shipped with your copy of windows.

Tags:

Views: 127 views. Averaging 0 views per day.
In the most recent 30 day period, there've been 0 views.

Similar Articles:
Retrieve Windows System Variables
Using Windows Media Center as a DVR Alternative -
Hollywood May Need to Rethink Release Windows to C
Hollywood May Need to Rethink Release Windows to C
Hollywood May Need to Rethink Release Windows to C

Previous Article | Next Article