Subform creates two records

When you are done we will *not* let the user see the RespID field in the SubForm. I would not expect my suggestions to put the RespID in a new record until you move to a different record on the subform.
 
You guys are on a real Merry-Go-Round. Do you want to get off?

The code containing the .AddNew is what is adding the additional record. Get rid of it.

The filter is not necessary. Get rid of it and set the master/child links on the subform to bind it to the mainform.

If the mainform isn't bound, bind it by placing a query in its RecordSource.

If you are using the field at the top of the form to find records to display in the subform, make sure that you are using an unbound field. Earlier you said that you were having a problem with keys being overlaid. This is indigative of bound fields being used as search fields.
 
Thank you Pat - On first go 'round that seems to work. However, when I go to enter the second record into the subform the cursor jumps back up to the first record. The RespID is locked, so the first available input is FLOR (Free Listing Original Rank). It is here that the cursor will jump to. The same thing happens when attempting to rerank on the right side under RANK, on the second record the cursor will jump back up to the first record under FLOR. It only happens the first time(when writing to the second record) after that its fine. Is there something I can do to prevent that, because that will definitely lead to some typos down the road.

Also, I used a SQL Statement to bind the Main form to the table, but when I used the wizard it just asked me for which table I want the form connected with, next I would bind a control to the primary key of the table, why could I not set that control to the record I wanted when ever I enetered the table? Should I always build a SQL statement when binding forms to tables instead of using the Access Wizards?
 
Should I always build a SQL statement when binding forms to tables instead of using the Access Wizards?
I use queries that I create and test outside of the form.

I can't tell what is wrong with the form without looking at it. All I can say is, it is your code causing the problem.
 

Users who are viewing this thread

Back
Top Bottom