Detect WSH, Script engine and DLL versionsTag(s): WSH VBScript
About cookies on this site
We use cookies to collect and analyze information on site performance and usage,
to provide social media features and to enhance and customize content and advertisements.
Dim WSHShell, FSO, VbDll, VbDllVersion, s
Set WSHShell = WScript.CreateObject("WScript.Shell")
WScript.Echo "WSH version : " & WScript.Version
s = ""
s = ScriptEngine & " Version "
s = s & ScriptEngineMajorVersion & "."
s = s & ScriptEngineMinorVersion & "."
s = s & ScriptEngineBuildVersion
WScript.Echo "Script engine version : " & s
Set FSO = WScript.CreateObject("Scripting.FileSystemObject")
If WSHShell.Environment.item("OS") = "" Then
' we assume a non-NT system
VbDll = "c:\windows\system\vbscript.dll"
Else
VbDll = "c:\winnt\system32\vbscript.dll"
End If
VbDllVersion = FSO.GetFileVersion(VbDll)
WScript.Echo "VBScript Dll version : " & VbDllVersion & " (" & VbDll & ") "
Set WSHShell = Nothing
Set FSO = Nothing
WScript.Quit(0)