Started to get a Run-Time error '3159'; Not a Valid bookmark all of a sudden in Access 2007 -


I'm really new to programming reach. I changed an old 97 access db to reach 2007 and it's a while Is working fine for Today I go into it and was moving around the design scene and was looking at the code. I did not change anything. Just saw when I went to run the code, I did get a "not valid bookmark" error only to ensure that I changed the old program and all the code is the same which is causing me problems

Mys Bookmark = Status

The following

  Private Sub Product ID / AfterUpdate () Dim pos as Variant Me! [UnitPrice] = Me! [ProductID]. Columns (2) [Product Name] = Me! [Producer]. Columns (1) Me! [GLAcct] = me! [Producer]. Column (3) DoCmd.DoMenuItem acFormBar, acRecordsMenu, acSaveRecord, acMenuVer70 pos = me.Bookmark me .Rquery Me. Bookmark = pause and sub  

EDIT: I have tried compact and repair.

You have to change this code because it is a while old. I'm not sure why this works in the first place, because the updates will be saved, after saving and if necessary, the bookmarks have changed. I have commented on the requery line because it does not seem to serve a useful purpose, if you want to update the combo, requatory If you want to find a record after a job, save the unique ID in one variable and Find it. DoMenuItem dislikes, you can use RunCommand instead, in this case, however, Me.Dirty = false will save.

  Private Sub ProductID_AfterUpdate () Deep Point as a way to me! [Unicotrice] = I! [Producer]. [Producer] me! [Product name] = i! [Producer]. Columns (1) Me! [Glaxat] = I! [Producer]. Columns (3) m Dirty = false 'pos = me. BOOKMARK' ME.Requery 'Me.Bookmark = pos End Sub  

Comments

Popular posts from this blog

oracle - The fastest way to check if some records in a database table? -

php - multilevel menu with multilevel array -

jQuery UI: Datepicker month format -