Retrieving BIOS information using WMI
- By Ramesh Srinivasan
- Published April 5, 2006
I'd like to know if there is a way to determine the BIOS version of a given computer without rebooting and entering the BIOS at boot. In other words, is there some utility within XP that will display the BIOS version?
The BIOS information can easily be retrieved using a WMI script. Also, the same script can be run against a list of computers in your network and generate the output from the machine where you sit.
Here is a sample script that gathers the BIOS information from the local system. (Watch for line wraps)
Set objWMI = GetObject("winmgmts:\\" & strComputer & "\root\CIMV2")
Set colItems = objWMI.ExecQuery("SELECT * FROM Win32_BIOS")
For Each itm In colItems
strBIOSVersion = Join(itm.BIOSVersion, ",")
WScript.Echo "BIOSVersion: " & strBIOSVersion
WScript.Echo "BuildNumber: " & itm.BuildNumber
WScript.Echo "SMBIOSBIOSVersion: " & itm.SMBIOSBIOSVersion
WScript.Echo "SMBIOSMajorVersion: " & itm.SMBIOSMajorVersion
WScript.Echo "SMBIOSMinorVersion: " & itm.SMBIOSMinorVersion
WScript.Echo "Version: " & itm.Version
Next
Additional resources
Microsoft Windows 2000 Scripting Guide - Retrieving Information About the BIOS
Microsoft TechNet: Scriptomatic Tool
