Access problems with inputting new records by subform

Puffin

New Member
Joined
Oct 13, 2004
Messages
2
I have created a main form with several tabbed subforms. When I add a new record the details on the main form are stored, but when I go to a subform I get a message saying that data can not be added as duplicate values are created. I have checked this and it does not seem to be the case. If I exit the form and reenter I can add the information to the subforms without any problems. Bizarre or what. Please help
 

Excel Facts

Why does 9 mean SUM in SUBTOTAL?
It is because Sum is the 9th alphabetically in Average, Count, CountA, Max, Min, Product, StDev.S, StDev.P, Sum, VAR.S, VAR.P.
Hello and welcome.

I can't answer your question directly but I have seen similar problems resolved by "requerying" the form when it becomes active. Have you tried doing this? Even if this doesn't solve your problem, your post will now get "bumped" and someone else may be able to help.

Andrew. :)
 
Upvote 0
Yes requerying the form does work. This is fine for when I am inputting the data. But I am hoping my colleagues will also be inputting data. It would be much easier if the form worked the first time.
Puffin
 
Upvote 0
Oops - sorry for not explaining myself 100% - when I mentioned "requerying the form" I meant via a macro attached to the form properties. It is possible to create a macro with two commands (i.e. requery and stop macro) and then include it in one of the "event" properties while in the form design mode - I'm not sure which "event" to use for tabbed subforms (something like "On Load" or "On Open"?) - apologies for being so vague.
Andrew. :)
 
Upvote 0

Forum statistics

Threads
1,221,825
Messages
6,162,165
Members
451,750
Latest member
dofrancis

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top