<<Windows internals 5th editon>> page 48.
strComputer="."
Set objWMIService = GetObject("winmgmts:"_
&"{impersonationLevel = impersonate}!\\"&strComputer &"\root\cimv2")
Set colOperatingSystem = objWMIService.ExecQuery _
("SELECT * FROM Win32_OperatingSystem")
For Each objOperatingSystem in colOperatingSystem
Wscript.Echo "Caption: " & objOperatingSystem.Caption
Wscript.Echo "Debug: " & objOperatingSystem.Debug
Wscript.Echo "Version: " & objOperatingSystem.Version
Next