I am writing a reference guide and wondering if I can check
whether some files exist from a page.
If it exists then I can forward the user to one page.
And if not they will see another page.
Grateful if someone points me to the right direction.
You need to use double backslashes in your file path
reference. Your script is correct except this line:
if(fso.FileExists("C:\Program Files\Common Files\My
It should read this:
if(fso.FileExists("C:\\Program Files\\Common Files\\My
The technical reason for this is that there are special
characters that you can not directly use in a string. In this case,
your path is the string. Backslash happens to be one of the special
characters that you can not directly use in a string. To get around
this, you need to do something called an escape sequence. In this
case, the escape sequence for \ is \\.