Need to rewrite code for checking if a file exists
Posted on 2016-10-26
I have this script which determines if the file exists:
if fs.FileExists("c:\inetpub\wwwroot\"&(rsProducts4("ImageSrc"))&"") then
response.write" The file c:\inetpub\wwwroot\"&(rsProducts4("ImageSrc"))&" does not exist."
My problem is that the database field (rsProducts4("ImageSrc")) has the format images/somefile.jpg
The problem is the slash. I need to change the script where the fs.FileExists evaluation is performed as to interpret the "/" as "\" as I cannot change it in the db. Any adea on how to rewrite this?
Thanks in advance.