File Exists
This function will return True if the file exists and False if the file does not exist
Private Function FileExists(sFileName As String) As Boolean
Dim sreturn As String
sret = Dir(sFileName)
If Len(sreturn) > 0 Then
FileExists = True
Else
FileExists = False
End If
End Function
Function File_Exists(sFileName As String) As Boolean
Dim fso As New Scripting.FileSystemObject
File_Exists = fso.FileExists(sFileName)
Set fso = Nothing
End Function
© 2024 Better Solutions Limited. All Rights Reserved. © 2024 Better Solutions Limited TopPrevNext