método FileExists do ASP

definição e uso

O método FileExists pode retornar um valor booleano que indica se o arquivo especificado existe. Se existir, retorna True, caso contrário, retorna False.

sintaxe:

FileSystemObject.FileExists(filename)
parâmetro descrição
filename obrigatória. Necessário verificar se o nome do arquivo existe.

instância

<%
dim fs
set fs=Server.CreateObject("Scripting.FileSystemObject")
if fs.FileExists("c:\asp\introduction.asp")=true then
  response.write("Arquivo c:\asp\introduction.asp existe!")
else
   response.write("O arquivo c:\asp\introduction.asp não existe!")
end if
set fs=nothing
%>