G
Guest
I am having a problem with the following code:
Dim obj As AccessObject, dbs As Object
Set dbs = Application.CurrentData
For Each obj In dbs.AllTables
If obj.IsLoaded = True Then
If TblObj.Name = strHoldTableName Then
MsgBox "Another user is viewing this record"
intBeingViewed = 1
Exit For
End If
End If
Next obj
This code is intended to check if a table with the (string) name
strHoldTableName exists, but it's not working. Am I missing a reference, or
is there another set of code that I should be using for this purpose?
Thanks in advance for your assistance!
Dim obj As AccessObject, dbs As Object
Set dbs = Application.CurrentData
For Each obj In dbs.AllTables
If obj.IsLoaded = True Then
If TblObj.Name = strHoldTableName Then
MsgBox "Another user is viewing this record"
intBeingViewed = 1
Exit For
End If
End If
Next obj
This code is intended to check if a table with the (string) name
strHoldTableName exists, but it's not working. Am I missing a reference, or
is there another set of code that I should be using for this purpose?
Thanks in advance for your assistance!