Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Edits getting lost

Background:

Split access database, maximum two users. The back end is located on one of the two computers on a mapped drive and the front end is local. The computers are connected to the router by wifi. (I am trying unsuccessfully to get them to connect the computers via cable)

Edit: This problem is now happening in a single user environment.

Problem:

This is happening on one specific form only. Its underlying table has a multi-value field.

Issue 1: We have a situation where a field will be edited, but as soon as the focus moves to another field the edit reverts back to its original value.

Issue 2: When editing one field, some of the other fields are getting the values of the previously shown record.

Note: Navigation from one record to the other is done as follows:

    Me.RecordsetClone.FindFirst "ID = " & cmbLocateRecipientID
    Me.Bookmark = Me.RecordsetClone.Bookmark

The issues only happen occassionaly.

This is an extremely weird behaviour on the part of Access, so when the users first reported the issues I was convinced that they were entering information mistakenly into another record. However, they have since shown me the issue happening live.

Closing and reopening the form solves the issue. However, they can obviously not work in such a fashion.

I cannot reproduce the problem on my development machine.

like image 813
E Mett Avatar asked Jul 15 '15 08:07

E Mett


1 Answers

Me would think you have to specify and use the recordset object:

Dim rs As DAO.Recordset

Set rs = Me.RecordsetClone
rs.FindFirst "ID = " & Me!cmbLocateRecipientID.Value & ""
If Not rs.NoMatch Then
    Me.Bookmark = rs.Bookmark
End If

Set rs = Nothing

A similar change may be needed in other parts of your code.

like image 101
Gustav Avatar answered Sep 21 '22 08:09

Gustav