Replica Error Messages on data entry and on exit

ptaylor-west

Registered User.
Local time
Today, 21:08
Joined
Aug 4, 2000
Messages
193
2 Problems, both connected with a replica database - I do not get these on the master.

The first one is a real problem, I create a new record for a new person on a summary form then I open another form with a command button and the filter is the persons name that I have just entered but as soon as I start to enter information on the second form I get the error message:

"Could not update, currently locked by another session on this machine"

Remember this doesn't happen on the Master database.

Second problem is that when I exit the replica I get the folowing message:

"Changes to this object can only be made only at the Design Master"

yet I have only entered data, I have to cancel this several times to exit


Any ideas?
 
I found this on the net for the "Could not update, currently locked by another session on this machine".... and it works which means there must be something that is a bit more elegant to work around this problem... any ideas?

Remember I still have the second problem.


This problem exists when using a MEMO field (also tested with OLE Object field and get the same error). The senario is that data is entered into this MEMO field. Later the field is edited and more data added. This continues to work until the field has around 2k worth of characters at which time an attempt is made to save the record and then the error message "Could't Update; Currently Locked by Another Session on this Machine" appears.

One work around seems to be to add another record and then come back to this record and then you can get past the 2k limit. But then the extra record needs to be deleted.
 
I have since found this article:

I've found the answer! It seems the error-handling in my vba code was
not robust enough, on occasion forcing execution to end in the middle
of a transaction. So to unlock the records I type
Workspaces(0).CommitTrans in the immediate window.
Hope this helps someone else!

But where do I put this code?
 
Further enquiries found this solution to the "Changes to this object can only be made only at the Design Master" and it works perfectly.


Remember I still have my other problem.



This is a form error, it is dealt with by the Form_Error event – go to On Error under the event tab of the form properties and create an event, which comes up as follows:
Private Sub Form_Error(DataErr As Integer, Response As Integer)
End Sub
In the first instance I would put:
Private Sub Form_Error(DataErr As Integer, Response As Integer)
Msgbox DataErr
End Sub
This will give you a number for what the error is.
Then take out Msgbox DataErr and replace with:
If DataErr = TheEstablishedErrNumber Then
Response = acDataErrContinue
Else
Response = acDataErrDisplay
End if
NOTE:
This is not a panacea, as some errors are caused for very different reasons therefore I'd advise caution when using the work-around.
 
Hi Uncle Gizmo,

Nothing happens unless you enter anything, actually I think it is because the data affects changes to a small graph on the form and this may be the culprit as the programm thinks your changing the layout, which I suppose you are.

Whatever, the solution works but I still have the other problem - the solution to enter another new record works, equally I found if I only changed one field it doesn't throw a wobler, so there may be something in the size of information that is locking it up. One of the leads I came across was something to do with the amount of fields and early termination but it wasn't well explained/argued so I didn't pursue it.
 
Last edited:
It is definitely the graph that is causing the error message and I can't alter it as when new data is entered the graph changes. Not a problem as the solution I have is OK, so that's that one sorted and I appreciate your help Uncle Gizmo.

I still would like a more elegant way to solving the "Could not update, currently locked by another session on this machine"
 

Users who are viewing this thread

Back
Top Bottom