ACCESS

R

ROB

TABLE1 HAS SEVERAL FIELDS, ONE OF WHICH CURRENTLY HAS A COMBO BOX DISPLAYING
INFORMATION BASED FROM A FIELD IN TABLE 2.

UPON SELECTING AN ENTRY FROM THE COMBO BOX, I WOULD LIKE TO AUTO POPULATE
THREE ADDITION FIELDS IN TABLE1, TO MATCH THEIR CORROSPONDING FIELDS IN
TABLE2.

I HOPE THIS MAKES SENSE, AND THAT SOMEONE CAN ASSIST/DIRECT ME
THANKS
 
R

Rick B

NO NEED TO SHOUT!

Are you sure you want to put the data in the table? That is a little
redundant. Proper database design would dictate that you create a
relationship between the two tables and have ONE common field to create your
link, but that you do not actually move data into the second table.

For example, if you enter a ZIP code in a table, and you have another table
with all the ZIP, State, City, and County entries. When you select the ZIP
in your main table, you would not want the other four items to be copied to
your table.

Post back if you need help with the relationship, or if you have a valid
reason to grab the data and repeat it in your main table. A vlid reason
might include if the data was time sensative. Such as the closing price of
a stock. You might want to apply it to your main table because it will
change tomorrow.



Rick B
 
R

ROB

I would like to select an ID number from cboPersonID and populate the
FirstName, MiddleName & LastName fields on the form with data from
tblPersons. Currently I can only populate one field. (FirstName or MiddleName
or LastName).

I know this is a bad example. It’s just a quick DB to learn how to perform
this function, it has no other purpose.

FrmNewPersons (for data input to tblNewPersons)

cboPersonID
Bound Column…1
Column Count…4
Column Widths…1â€;0â€
Row Source Type…Table/Query
Row Source…SELECT [tblPersons].[ID], [tblPersons].[FirstName],
[tblPersons].[MiddleName], [tblPersons].[LastName] FROM tblPersons;

After Update…
Private Sub cboPersonID_AfterUpdate()
Me.FirstName.Value = Me.cboPersonID.Column(1)
End Sub

TextBox1… FirstName
TextBox2… MiddleName
TextBox3… LastName

TblPersons; ID, FirstName, MiddleName, LastName

TblNewPersons; ID, FirstName, MiddleName, LastName
 
Top