Monday, October 30, 2017

To check whether file exist in the specified path or not

Function fnFileExists_InSpecifiedPath(str_Path_FileName)
On Error Resume Next
'Specify the Path as well along with file name
Set fso = CreateObject("Scripting.FileSystemObject")
fnFileExists_InSpecifiedPath = fso.FileExists(str_Path_FileName)
    Set fso = Nothing
End Function

No comments:

Post a Comment