Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations TouchToneTommy on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Populate field in one table w/ combo box selection of another table

Status
Not open for further replies.

etalent

Programmer
Jun 9, 2003
23
US
How do I populate a field in one table by selecting from a combo box with a control source of another table.

I've got 4 tables, with fields and relations as follows...

tblInfinitives
fldInfId
fldConId
fldInfEng
fldInfEsp
fldInfPor

tblConjugations
fldConId
fldConEsp
fldEspTenseId
fldConPor
fldPorTenseId

"tblConjugations.fldConId" has 1 record related to many records in "tblInfinitives.fldConId"

tblEspTenses
fldEspTenseId
fldEspPresentParticiple
fldEspPastParticiple
fldEspImperative

"tblConjugations.fldEspTenseId" has a 1 to 1 relationship with "tblEspTenses.fldEspTenseId"

tblPorTenses
fldPorTenseId
fldPorPresentParticiple
fldPorPastParticiple
fldPorImperative

"tblConjugations.fldPorTenseId" has a 1 to 1 relationship with "tblPorTenses.fldPorTenseId"

"qryVerbs" is a query, which includes all of the fields of all of the tables.

"frmVerbs" is a form with a bunch of text boxes and 2 combo boxes. These controls and their control sources are as follows:

"txtEng" is a text box with control source "qryVerbs.tblInfinitives_fldInfEng"

"txtEsp" is a text box with control source
"qryVerbs.tblInfinitives_fldInfEsp"

"txtPor" is a text box with control source
"qryVerbs.tblInfinitives_fldInfPor"

"txtEspPresentPart" is a text box with control source
"qryVerbs.tblEspTenses_fldEspPresentParticiple"

"txtEspPastPart" is a text box with control source
"qryVerbs.tblEspTenses_fldEspPastParticiple"

"txtEspImperative" is a text box with control source
"qryVerbs.tblEspTenses_fldEspImperative"

"txtPorPresentPart" is a text box with control source
"qryVerbs.tblPorTenses_fldPorPresentParticiple"

"txtPorPastPart" is a text box with control source
"qryVerbs.tblPorTenses_fldPorPastParticiple"

"txtPorImperative" is a text box with control source
"qryVerbs.tblPorTenses_fldPorImperative"

"cboEspCon" is a combo box, and "cboPorCon" is a combo box, the control source of both is what I need help with.

Here is a description of the desired functionality of form "frmVerbs"...

1. Enter a value in "txtEng," "txtEsp," and "txtPor"

2. Select a value from either "cboEspCon" or "cboPorCon," which sets the value for "tblInfinitives.fldConId", and in turn, sets the values of all of the remaining text boxes.

In other words, it's very simple. You enter a word in "txtEng," in "txtEsp," and in "txtPor."

Then you select a value from "cboEspCon" or "cboPorCon," which, in turn, sets the values of "txtEspPresentPart," "txtEspPastPart," "txtEspImperative," "txtPorPresentPart," "txtPorPastPart," and "txtPorImperative."




 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top