B
Bob
When a file is local to the ASP application, I can use the following code to
test if the file exists:
Dim strFileName, blnFileExists, objFSO
strFileName = Server.MapPath( "\MyFiles\test.doc" )
Set objFSO = Server.CreateObject("Scripting.FileSystemObject")
blnFileExists = objFSO.FileExists( strFileName )
Set objFSO = Nothing
But if "MyFiles" resides on another server and I set up a virtual directory
in my ASP app to reference to it (e.g. "\MyFiles\test.doc" resolves to
\\server2\F$\MyFiles\test.doc), the code would return False even if the file
exists on the other server.
Is there a way to test the existence of a file that resides on another
server?
test if the file exists:
Dim strFileName, blnFileExists, objFSO
strFileName = Server.MapPath( "\MyFiles\test.doc" )
Set objFSO = Server.CreateObject("Scripting.FileSystemObject")
blnFileExists = objFSO.FileExists( strFileName )
Set objFSO = Nothing
But if "MyFiles" resides on another server and I set up a virtual directory
in my ASP app to reference to it (e.g. "\MyFiles\test.doc" resolves to
\\server2\F$\MyFiles\test.doc), the code would return False even if the file
exists on the other server.
Is there a way to test the existence of a file that resides on another
server?