Cannot add record(s); join key of tablename not in result set.(Err

G

Guest

Getting this weird unhelpful error, when attempting to populate a date field
with a calendar entry on a On dbl Click event. Full message is :-

Run-time Error '-2147352567 (800200009)';

Cannot add record(s); join key of tablename not in recorset.

I have over 20 of these events in various forms without any problem, so it
must lie within the subform. I have put all the relevant code in place in the
subform as required, but nothing seems to work.

Suggestions please.

Cheers,
Steve
 
R

Roger Carlson

Apparently you are using a Join as the RecordSource for a subform.
Generally, you join two tables on the primary key from the "one"-side table
and the foreign key from the "many"-side table. You have chosen the primay
key to display in the recordset rather than the foreign key field. Make
sure you list the "Join" field from the "many"-side table in the Recordset.

--
--Roger Carlson
Access Database Samples: www.rogersaccesslibrary.com
Want answers to your Access questions in your Email?
Free subscription:
http://peach.ease.lsoft.com/scripts/wa.exe?SUBED1=ACCESS-L
 
G

Guest

Roger,
The subform in question has 3 tables joined in the record source as 1-m-m,
the only 'selected' key field is from the 3rd table which is indeed a primary
key. As this is not joined to a 4th table and used as a foreign key
reference, I don't see why access should object. Am I missing something here?
 

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