Script to test Windows performance

June 2017


Issue


How i can use a script to access Windows? A script that work like the rating method in windows Vista and Seven?

Solution

  • Open a notepad
  • Copy the below script ;

strComputer = "." 
Set objWMIService = GetObject("winmgmts:\\" & strComputer & "\root\cimv2") 
Set colItems = objWMIService.ExecQuery("Select * From Win32_WinSAT") 
For Each objItem in colItems 
Select Case objItem.WinSATAssessmentState 
Case "0","3" 
msg = "Warning, tests did not well" 
Case "1" 
msg = "Results are available..." 
Case "2" 
msg = "Warning: Inconsistent results" 
Case "4" 
msg = "Warning invalid tests" 
End Select 
msg = msg + VBCRLF + "CPU: " & objItem.CPUScore 
msg = msg + VBCRLF + "Ram: " & objItem.MemoryScore 
msg = msg + VBCRLF + "Hard disk: " & objItem.DiskScore 
msg = msg + VBCRLF + "GPU: " & objItem.GraphicsScore 
msg = msg + VBCRLF + "Game performance: " & objItem.D3DScore 
msg = msg + VBCRLF + "Average rating: " & objItem.WinSPRLevel 
Wscript.Echo msg 
Next 
  • Save and named the notepad as "ShowWinSat.VBS"
  • Double click on the file to launch the rating

Related


Published by aakai1056. Latest update on November 8, 2012 at 04:12 PM by Jeff.
This document, titled "Script to test Windows performance," is available under the Creative Commons license. Any copy, reuse, or modification of the content should be sufficiently credited to CCM (ccm.net).