my email is rshurer@hotmail.com
This is the script:
' osinfo.vbs by John Savill
strComputer = "."
Set objWMIService = GetObject("winmgmts:"
& "{impersonationLevel=impersonate}!\\" & strComputer
& "\root\cimv2")
Set colOperatingSystems = objWMIService.ExecQuery
("Select * from Win32_OperatingSystem")
For Each objOperatingSystem in colOperatingSystems
wscript.echo "Install Date: " &
objOperatingSystem.InstallDate
Wscript.Echo "Operating System: " &
objOperatingSystem.Caption
Wscript.Echo "Version: " &
objOperatingSystem.Version
Wscript.Echo "Checked Build: " &
objOperatingSystem.Debug
Wscript.Echo "Service Pack: " &
objOperatingSystem.ServicePackMajorVersion & "." &
objOperatingSystem.ServicePackMinorVersion
Next
When i press F8 to run it, i receive an error (see
attached file).
When i run the script in command line (cscript
<scriptname.vbs>) it runs ok.
Error message
Logged In: YES
user_id=466678
Script menu and F8 key are for scripts that control Syn
itself. You can find some examples of such scripts in
Scripts subfolder.
For testing of files like your you have to create custom
tool and set:
Toolkind: Launch program
Program: cscript.exe
Arguments: $[ActiveDocShort]
Capture console: checked
Regards,
Danail