'''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''
'show dll version' script
'2007 Moo(ASP++)
'''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''
dim fxhome
fxhome="c:\windows\Microsoft.NET\Framework\v2.0.50727"
ShowVersion(fxhome+"\aspnet_isapi.dll")
ShowVersion(fxhome+"\system.web.dll")
ShowVersion(fxhome+"\aspnet_wp.exe")
'''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''
sub ShowVersion(sPath)
WScript.Echo (spath+"="+GetVersion(spath) )
end sub
''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''
Function GetVersion(pathspec)
Dim fso, temp
Set fso = CreateObject("Scripting.FileSystemObject")
temp = fso.GetFileVersion(pathspec)
If Len(temp) Then
GetVersion = temp
Else
GetVersion = "バージョン情報はありません。"
End If
End Function
実行結果:
C:\>cscript "C:\moreinfo.vbs"
c:\windows\Microsoft.NET\Framework\v2.0.50727\aspnet_isapi.dll=2.0.50727.42
c:\windows\Microsoft.NET\Framework\v2.0.50727\system.web.dll=2.0.50727.210
c:\windows\Microsoft.NET\Framework\v2.0.50727\aspnet_wp.exe=2.0.50727.210