Leaked source code of windows server 2003
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

22 lines
754 B

  1. '***************************************************************************
  2. 'This script tests the GetInstance operation using XML/HTTP
  3. '***************************************************************************
  4. on error resume next
  5. Dim objLocator
  6. Set objLocator = CreateObject("WbemScripting.SWbemLocator")
  7. Dim objService
  8. Set objService = objLocator.ConnectServer("[http://localhost/cimom]", "root\cimv2")
  9. if err <> 0 then
  10. WScript.Echo ErrNumber, Err.Source, Err.Description
  11. else
  12. WScript.Echo "ConnectServer Succeeded"
  13. end if
  14. Set firstProcessor = objService.Get("win32_processor.DeviceID=""CPU0""")
  15. if err <> 0 then
  16. WScript.Echo ErrNumber, Err.Source, Err.Description
  17. else
  18. WScript.Echo firstProcessor.description
  19. end if