After creating a new Project record I'd like to have a button on my Project Form called "New Bid" that opens the related Bid Form to a new record, copies the ProjectID in the related field on the Bid Table, and displays the "Project Name" field only (no ID), from the Project Form/Table, on the top of the Bid form from. Thank you all for the help. You're awesome!
Sorry Kevin, that's not really what I'm looking for.
Adam Schwanz 2 months ago
Can you elaborate some more then? Maybe with pictures? That sounds exactly like what a default value is for.
The only other thing I could think you may be talking about is DLookup but that only maybe applies to the last part of your question.
Caleb Hansen 2 months ago
Sure. Thanks for your patience. I have 2 related tables, ProjectT and BidT. BidT has the foreign key of ProjectID from the ProjectT. I also have 2 forms, ProjectF and BidF. After filling out the fields in the ProjectF, the user clicks the "BidButton" to "DoCmd.OpenForm "BidF", , , , acFormAdd." I'd like for that button to also carry the ProjectID that was just created in the ProjectF into the foreign key field of the BidT so that the user doesn't have to keep entering this info. I would like the BidF to open with the ProjectName, sharing the same ProjectID above, in a Textbox at the top of the form. I agree that last part should probably be a Dlookup function, but I'm a bit fuzzy on the code for the criteria. For the first part, I don't see in the default value videos an example of what I'm looking to do. All of this would be moot if I just made BidF a subform, but BidF will have its own subform and it will be getting too big a crazy at that point. Thanks again
Sorry, only students may add comments.
Click here for more
information on how you can set up an account.