Source language: Translate to:

Posting edits problem

Questions about our Advanced Database plug-in

Moderator: Neosoft Support

Posting edits problem

Postby BRobinsonS » Mon Aug 20, 2012 1:07 pm

I enhanced the Address Book sample to a membership app.

I added a 'Save Changes' button using dbpSaveEdits to save changes while working on a new record. So I don't have to move off a record to save changes. But I get this error message and can't get off the record I am on and have to shut down the application.

Error Message:
Row cannot be located for updating. Some values may have changed since it was last read


I also noticed there is a dbpSetAutoEdit command which is set true when opening a table. Tried this in the code but didn't seem to help.

Could someone shed light on what is happening?
Brian Robinson
'When all else fails, try again!'
www.ComputerSoftwareSystems.com
User avatar
BRobinsonS
 
Posts: 337
Joined: Sun Sep 25, 2005 9:00 pm
Location: Ontario, Canada

Postby Neosoft Support » Wed Aug 22, 2012 12:17 pm

This error occurs with MS Access databases when a table does not contain a primary key field. The easiest way to resolve the problem is to add an auto increment field to the table and make it the primary key.
NeoSoft Support
Neosoft Support
NeoSoft Team
 
Posts: 5593
Joined: Thu Mar 31, 2005 10:48 pm
Location: Oregon, USA

Postby BRobinsonS » Wed Aug 22, 2012 5:52 pm

Thanks for the tip.

:D

Will do.
Brian Robinson
'When all else fails, try again!'
www.ComputerSoftwareSystems.com
User avatar
BRobinsonS
 
Posts: 337
Joined: Sun Sep 25, 2005 9:00 pm
Location: Ontario, Canada

Postby BRobinsonS » Thu Aug 23, 2012 8:25 am

This error occurs with MS Access databases when a table does not contain a primary key field.

The table has an index.

I know I can list the indices but is there a way to get the index information
i.e. fields that make up the index, primary key = yes/no, unique=yes/no ?

I don't have MS Access on my computers.
Brian Robinson
'When all else fails, try again!'
www.ComputerSoftwareSystems.com
User avatar
BRobinsonS
 
Posts: 337
Joined: Sun Sep 25, 2005 9:00 pm
Location: Ontario, Canada

Postby Neosoft Support » Thu Aug 23, 2012 10:11 am

If you're getting the "Row cannot be located for updating..." error then your table does not contain a primary key field. That's the only thing that can cause that error.

You can use the dbpGetFieldDefs to see what fields your table contains. If there is no primary key field, you can use dbpAddField to add one.

It is not necessary to have MS Access installed.
NeoSoft Support
Neosoft Support
NeoSoft Team
 
Posts: 5593
Joined: Thu Mar 31, 2005 10:48 pm
Location: Oregon, USA

Postby BRobinsonS » Thu Aug 23, 2012 10:35 am

Used dbpGetFieldDefs on one database and it has primary key.

The database I am having trouble with has no primary key.
Guess that should solve it.

Thank you again for prompt response and patience.
Brian Robinson
'When all else fails, try again!'
www.ComputerSoftwareSystems.com
User avatar
BRobinsonS
 
Posts: 337
Joined: Sun Sep 25, 2005 9:00 pm
Location: Ontario, Canada


Return to NeoBookDBPro

Who is online

Users browsing this forum: No registered users and 1 guest