Add New Record Button

G

Guest

Hi All! Been working with a form and 4 subforms. All the subforms have an Add
New Record Button. Now, when I put fake data into the form, click on the Add
New Record Button, it gives me this error "You can't go to the specific
record". I don't want to go to a specific record. All I want to do is add
this record to the table. Anyone come across this error before.
 
J

John Vinson

Hi All! Been working with a form and 4 subforms. All the subforms have an Add
New Record Button. Now, when I put fake data into the form, click on the Add
New Record Button, it gives me this error "You can't go to the specific
record". I don't want to go to a specific record. All I want to do is add
this record to the table. Anyone come across this error before.

Care to give us a bit of help - e.g. posting the code executed by the
button's Click event?

John W. Vinson[MVP]
 
G

Guest

John,
Here's the code you requested. To me everyhting looks all right. But I am
not a VB programmer. I got an error this morning about not being able to add
a record because of having the a key would be duplicated. I'll have to check
this today. Thanks for any help in advance.

Keith
 
J

John Vinson

John,
Here's the code you requested. To me everyhting looks all right. But I am
not a VB programmer. I got an error this morning about not being able to add
a record because of having the a key would be duplicated. I'll have to check
this today. Thanks for any help in advance.

A key being duplicated suggests a problem with the content of the data
rather than the structure of the code... which you still didn't post.

John W. Vinson[MVP]
 
G

Guest

Sorry John. You were right anyhow. After messing with the field and the
relationships, I got the right things that should happen when I click on the
Add New Record button. Thanks for the help.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top