I tried using Shell and NameSpace to lookup file version numbers over a
share as in
\\abc\c$\installs but it fails to return the same info as c:\installs for
example
==========runme.vbs============
function GetFileVersion(ThisFolder, FileName)
dim objShell : set objShell = CreateObject("Shell.Application")
dim objFolder : set objFolder = objShell.NameSpace(ThisFolder)
dim objItem : set objItem = objFolder.ParseName(FileName)
GetFileVersion = ""
for i = -1 to 34
GetFileVersion = GetFileVersion & objFolder.GetDetailsOf(objItem,i)
& vbcrlf
next
end function
' assume that c:\temp contains notepad.exe and xxxxx is the computer name
' the following two lines of code return different information.
' in particular the i = -1 "File Version:" is missing on the share C$\temp
WScript.Echo GetFileVersion ("c:\temp", "notepad.exe")
WScript.Echo GetFileVersion ("\\xxxxx\c$\temp", "notepad.exe")
========================
Is there any other way to get file version info on .exe, .ocx, .dll ?
--
=======================================================================
Beemer Biker joestateson@grandecom.net
http://TipsForTheComputingImpaired.com
http://ResearchRiders.org Ask about my 99'R1100RT
=======================================================================