P
Paul3rd
Hello, I have in my split database a form that relies on one table (ApptDis).
When a user on the network has that form open, I'd like to inform/block any
other user from opening the form by denying the table read property.
I've started working on the code to go in the OnOpen event of the form, and
so far I have:
Dim rst As Recordset
Dim Answer As Integer
Answer = MsgBox("Form in use by another user...Please Wait", vbOKOnly)
Set rst = CurrentDb.OpenRecordset("ApptDis", dbOpenTable, dbDenyRead)
If Err.Number <> 0 Then
MsgBox ("Err Number = 0")
If Answer = vbOK Then
Exit Function
End If
End If
rst.Close
But it does not work, I get an error message saying that the table has a
process running and cannot be locked. I don't know what that process might be.
Am I on the right path? or am I going in the wrong direction entirely?
Any help would be greatly appreciated.
Paul
When a user on the network has that form open, I'd like to inform/block any
other user from opening the form by denying the table read property.
I've started working on the code to go in the OnOpen event of the form, and
so far I have:
Dim rst As Recordset
Dim Answer As Integer
Answer = MsgBox("Form in use by another user...Please Wait", vbOKOnly)
Set rst = CurrentDb.OpenRecordset("ApptDis", dbOpenTable, dbDenyRead)
If Err.Number <> 0 Then
MsgBox ("Err Number = 0")
If Answer = vbOK Then
Exit Function
End If
End If
rst.Close
But it does not work, I get an error message saying that the table has a
process running and cannot be locked. I don't know what that process might be.
Am I on the right path? or am I going in the wrong direction entirely?
Any help would be greatly appreciated.
Paul