what is the best way to see if a table exists in a backend database?
I’m using
Public Function DoesTableExist(strTable As String, Optional strDatabase As String) As Boolean
Dim dbs As DAO.Database
Dim tdf As DAO.TableDef
If strDatabase = “” Then
Set dbs = CurrentDb
Else
Set dbs = OpenDatabase(strDatabase)
End If
Set tdf = dbs.TableDefs(strTable)
DoesTableExist = Not (tdf Is Nothing)