This is what I think is the best method for determining if a
file exists or not. Just pass the filepath and name as a string.

VB Code:
  1. Option Explicit
  2.  
  3. Private Const OF_EXIST = &H4000
  4. Private Const OFS_MAXPATHNAME = 128
  5.  
  6. Private Type OFSTRUCT
  7.     cBytes As Byte
  8.     fFixedDisk As Byte
  9.     nErrCode As Integer
  10.     Reserved1 As Integer
  11.     Reserved2 As Integer
  12.     szPathName(OFS_MAXPATHNAME) As Byte
  13. End Type
  14.  
  15. Private Declare Function OpenFile Lib "kernel32" (ByVal lpFileName As String, lpReOpenBuff As OFSTRUCT, ByVal wStyle As Long) As Long
  16.  
  17. Public Function FileExists(ByVal sFile As String) As Long
  18.  
  19.     Dim lRetVal As Long
  20.     Dim OfSt As OFSTRUCT
  21.    
  22.     lRetVal = OpenFile(sFile, OfSt, OF_EXIST)
  23.     If lRetVal = 1 Then
  24.         FileExists = 1
  25.     Else
  26.         FileExists = 0
  27.     End If
  28.    
  29. End Function
  30.  
  31. 'Usage:
  32. Private Sub Command1_Click()
  33.     If FileExists("C:\DeleteMe\Test.txt") = 1 Then
  34.         Msgbox "File Exists!"
  35.     Else
  36.         'MsgBox "File Not Found!"
  37.     End If
  38. End Sub
VB/Outlook Guru!