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.

14 lines
374 B

  1. on error resume next
  2. while true
  3. set obj = GetObject("winmgmts:{impersonationLevel=impersonate}!win32_diskpartition.DeviceId=""Disk #0, Partition #1""")
  4. WScript.Echo obj.Path_.Class
  5. for each system in obj.Associators_ (,"Win32_ComputerSystem")
  6. WScript.Echo system.Name
  7. next
  8. if err <> 0 then
  9. WScript.Echo err.number, err.description, err.source
  10. end if
  11. wend