Can't enter new records

Maggie23

Registered User.
Local time
Today, 01:33
Joined
Jun 18, 2002
Messages
19
A form I have been using now won't let me add a new record. I have entered over 100 records with the form no problem so I'm not sure were this error is coming from.
One field(named AccessionID) on the form requires a unique number. When I type in a number I know is unique it comes back and tells me I can't go to specified record. Then if I try to close I get the message record can't be recorded as it would "...create a duplicate value in the index, primary key or relationship..." In the underlying table this field is the primary key. When I go back to the table and search to see if it's a duplicate, Access indicates there is no record to be found matching that number. I have not had any problem entering records directly to the table. I have tried several different numbers and the form just won't accept them.
The primary key field in the table is set as: required: no; index: Yes(no duplicates).

I have one field "LastID" that shows the last accessionID number used so I know the next one to use. That seems to be working so I don't think the problem is stemming from that.

The **only** thing I did to this database was to change the form's date field default value from =Now() to =Date(). When I started having problems I changed back to =Now() and deleted the records entered under =Date() and re-entered. So I don't see how that could have caused a problem. But I really have no clue why I can't enter new records.
Sorry so long winded - but I hope someone can help.
Thanks
Maggie
 
Is your primary key an auto number? It would be better to let your table generate the primary key as an auto number, and if required have your own number field set for no duplication. Just checking!
 
How about some history on this form. Is this form part of a database written by you? Written by someone else for your organization? Something you found on the internet?

Some developers make dbs available for trial but limit the number of records and/or length of time the trial version may be used before purchasing the commercial version.

The Missinglinq

BTW Trevor, love your movies!
 

Users who are viewing this thread

Back
Top Bottom