The code is "As Is" I am not responsible for any bugs or problems it may create. I have been using it and I have not encounter any issues with it but it is the responsibility of the tech using the script to understand it and to be able to troubleshoot if any problems were to arise. Feel free to share and modify the code and make sure to provide a reference to my blog post.
Create a script or module and add the following lines of code to it:
Gets the computer manufacturer, model,BIOS version and serial number
This script uses WMI to retrieve instances of Win32_BIOS,
and gets the computer manufacturer, model,BIOS version and serial number.
Get-ComputerInfo -ComputerName LocalHost
This will get the manufacturer, model,BIOS version and serial number
on the local computer
Get-ComputerInfo -ComputerName ( Get-Content ./ComputerList.txt )
This will grab the computer list stored on the file ComputerList.txt
and use all them to get the manufacturer, model,BIOS version and serial number
on every computer on the list.
[Parameter(Mandatory=$true, ValueFromPipelineByPropertyName=$true, Position=0)]
Write-Verbose -Message "Getting information about computers: $ComputerName"
Get-WmiObject -ComputerName $ComputerName -class Win32_BIOS |
Select PSComputerName,Manufacturer,Model,SMBIOSBIOSVersion,SerialNumber |
Write-Verbose -Message "Done getting information about comptuers: $ComputerName"