Hello
I'm trying to read remote text files using this code:
function defdate(ipaddress)
deffilePath = chr(34) & "\\" & ipaddress & "\c$\" & deffileName & chr(34)
wscript.echo deffilePath
set deffile = objFSO.OpenTextFile(deffilePath)
do while not deffile.endofstream
s=deffile.readline
wscript.echo s
loop
deffile.close
end function
My deffilePath below expands into strings like this:
"\\10.211.19.207\c$\Program Files\Common Files\Symantec Shared\VirusDefs\definfo.dat"
However, I get "Microsoft VBScript runtime error: Bad file name or number".
What could be the problem?