Hi everyone - I'm using Access 365 under Windows 10.
I have a VBA procedure that includes the following code to add a new record to a table:
With rstSolution
.AddNew
!lngProblemNumber = 1
!lngSolutionNumber = lngVBACount0
!lngNumberOfValuesUsed = lngVBASolutionNumberOfProvidedValuesUsed(lngVBACou nt0)
!strConsolidatedComponent = strVBAConsolidatedComponent(lngVBACount0)
.Update
End With
When I run the code, I'm getting a run time 3164 error (Field cannot be updated). When I click the Debug option, the statement !lngSolutionNumber = lngVBACount0 is highlighted.
The explanation given in the help info says that another user or process has locked the relevant table - but I'm the only user! There is no other process running at the time either.
Can someone please explain why this would be happening and suggest a workaround. Is there a way of explicitly unlocking the table within VBA code?
Thanks in advance for any help!