• Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 3344
  • Last Modified:

"You can't go to the specific record" in Access

  We have an Access application who run on 2003/2007. When clicking a button the following VBA code is called:

Private Sub Commande87_Click()
On Error GoTo Err_Commande87_Click
    DoCmd.GoToRecord , , acNewRec

    Exit Sub
    MsgBox Err.Description
    Resume Exit_Commande87_Click
End Sub

The application is a MDE. It referes to linked tables (in a MDB) located on a map drive.

Sometimes, it gives the following error: "You can't go to the specific record".

This error shows up depending of the logged on Windows user. But we have 2 administrators who have full access to everything, both accounts are identical, and one does get the error and the other one doesn't. So I really don't understand the reason of this behavior.

thanks for your time and help
1 Solution
Are both administrators trying to add a new record at the same time? It can be a question of locks to the table that you're trying to go to new record, if one user has the table locked the other user can't go to new record.

Dominic34Author Commented:
both administrators are trying one after the other, it isn't at the same time.
if the form in edit mode and you call the goto new record , it give an error
so u should call
then u can call
DoCmd.GoToRecord , , acNewRec
Never miss a deadline with monday.com

The revolutionary project management tool is here!   Plan visually with a single glance and make sure your projects get done.

This behavior is not normally an occasional issue. Either you can, or you can't go to a new record depending on the state of the data in the view.
The primary reason you can't add a new record is obvious, you are trying to do so in a Read only scenario.

Form settings can cause this, also the recordset itself.

Is the underlying recordset a query with numerous joins? Do you have the setting "Add New Records" set to false on the form?

Dominic34Author Commented:
this is really strange. 2 distincts network administrators, both accounts are identical. When the first log on a computer (windows user), and log on the Access application using an administrator (admin of the Access database) account, it works fine. Then, he logout from Windows and the second admin log in, using his account. Both account are identical... And he log in the Access program using the same Access admin account, it give the error "you can't go to the specific record".

what in the hell that could be??!
Dominic34Author Commented:
jefftwilley, to answer your questions forms properties are fine, as far as I can say. The error is fired when trying to add a new record on a table (the "DoCmd.GoToRecord , , acNewRec" statement). I don't understand why it works with a specific user and don't with another user, when both account are identical ....
Ok, more primative options: :)

Is the database opening from a shortcut on the desktop?

if so, check permissions on the shortcut.

is the Read-Only attribute true?

Are the permissions to the Target directory the same for both admin?


Dominic34Author Commented:
We found out what was happening finally, after 2 weeks of frustrating research! The database is locate on a map drive. The map definition, for a user, used the share name of the map drive "Data$" and the other used the long network path "//serveur/founisseur/data". This error fired when we use the share name but never with the long network path. So, we changed all users who used the share name and it solved the problem!!

Featured Post

The 14th Annual Expert Award Winners

The results are in! Meet the top members of our 2017 Expert Awards. Congratulations to all who qualified!

Tackle projects and never again get stuck behind a technical roadblock.
Join Now