Populate with a List Box

Chris Watson

Registered User.
Local time
Today, 18:47
Joined
Jan 23, 2004
Messages
21
Is it possible to populate several fields on a form via a Nma e selected from a list box ie: the list box has several names in it, the names have data from another form (user details) such has Payrole No:, Holiday entitlement, etc.
I want to select a name from the List Box and have it populate (enter) data into field in the form being used.???
Ive tryed everything and can't find a solution.
Please help??
 
Is it possible to populate several fields on a form via a Nma e selected from a list box ie: the list box has several names in it, the names have data from another form (user details) such has Payrole No:, Holiday entitlement, etc.
I want to select a name from the List Box and have it populate (enter) data into field in the form being used.???
Ive tryed everything and can't find a solution.
Please help??

I use code that does it from a combobox. I just assign the combo selection columns to the appropriate textboxes in the form.

Me.YourTextBoxName1 = Me.YourComboName.Column(1)
Me.YourTextboxName2 = Me.YourComboName.Column(2)
Me.YourTextBoxName3 = Me.YourComboName.Column(3)

And So forth ...
 
Thanks Wiz But im new to access, Where would I put this code???
 
Put the code in the AfterUpdate event of the list box.

Dave
 
Populate via ComboBox

If I do it this way, dose this mean that the ComboBox will have several columns ie:
Name,Regestration,Payrole No etc.
What Im looking for is a ComboBox that will show the name only, and from that name selected populate the other fields Regestration, Payrole No etc. I would like to see an example of a similar db.
Can you help???
 
Use The Width For each column these can be set like 0cm;2cm;0cm;0cm This will only diplay the second column to the user but you can reference the other three columns

mick
 

Users who are viewing this thread

Back
Top Bottom