Hi,
I have some code that finds a table and deletes it from access; however, I'm trying to delete an oracle linked table and not being successful. Here's what I have:
Function X
If tableExists("" & tabName & "") Then
DoCmd.DeleteObject acTable, "" & tabName & ""
Debug.Print "Deleting table:"; tabName; ""
Else
End If
End Function
Private Function tableExists(table As String) As Boolean
On Error GoTo no
CurrentDb.OpenRecordset (table)
tableExists = True
GoTo theend
no:
tableExists = False
theend:
End Function
Any ideas as to why this would be? Thank you!
I have some code that finds a table and deletes it from access; however, I'm trying to delete an oracle linked table and not being successful. Here's what I have:
Function X
If tableExists("" & tabName & "") Then
DoCmd.DeleteObject acTable, "" & tabName & ""
Debug.Print "Deleting table:"; tabName; ""
Else
End If
End Function
Private Function tableExists(table As String) As Boolean
On Error GoTo no
CurrentDb.OpenRecordset (table)
tableExists = True
GoTo theend
no:
tableExists = False
theend:
End Function
Any ideas as to why this would be? Thank you!