I have a form that has a key to backup a table called Clients
I created a function:
Private Function FileExists(ByVal FileName As String) As Boolean
FileExists = Len(Dir(FileName)) > 0
End Function
Public Backup_click()
Dim StrFile as String
StrFile = "Clients"
if fileExits(strFile) = False then
msgbox "File Does not exists"
End if
'do other stuff
End Sub
I am getting File Does not exists at all time even thought the table exists.
Please advise,
thank you.
I created a function:
Private Function FileExists(ByVal FileName As String) As Boolean
FileExists = Len(Dir(FileName)) > 0
End Function
Public Backup_click()
Dim StrFile as String
StrFile = "Clients"
if fileExits(strFile) = False then
msgbox "File Does not exists"
End if
'do other stuff
End Sub
I am getting File Does not exists at all time even thought the table exists.
Please advise,
thank you.