Hello,
I've been trying to automatically populate the field value based on a combo box selection. I've looked for help in many postings and everything that I try simply doesn't work for me.
I have a couple of fields in a table that has ID numbers and all I need is their descriptions to automatically populate. I don't need to select more than one choice per combo box. Once data is collected it will be stored into a table. I am using a form to make these selections. My first combo box is a UserID box, which I need the very next field to populate the UserID Name. I will also have another combo box on the same form for Account#, then I need Account Name (this information is not in the User_IDs table.
For my first combo:
On the row source of the UserID I have the following code: SELECT [User_IDs].[UserID] FROM User_IDs ORDER BY [UserID];
Things that I have tried and hasn't worked so far, not sure what I am doing wrong. Tried on After Update, On Change, Click...
Private Sub UserIDs_AfterUpdate()
Me.User_Name = Me.UserIDs.Column(1)
End Sub
I don't how to create a column count if that's need.
Any help is greatly appreciated or other suggestions. I've spent a lot time reading through postings. Thanks all.
I've been trying to automatically populate the field value based on a combo box selection. I've looked for help in many postings and everything that I try simply doesn't work for me.
I have a couple of fields in a table that has ID numbers and all I need is their descriptions to automatically populate. I don't need to select more than one choice per combo box. Once data is collected it will be stored into a table. I am using a form to make these selections. My first combo box is a UserID box, which I need the very next field to populate the UserID Name. I will also have another combo box on the same form for Account#, then I need Account Name (this information is not in the User_IDs table.
For my first combo:
On the row source of the UserID I have the following code: SELECT [User_IDs].[UserID] FROM User_IDs ORDER BY [UserID];
Things that I have tried and hasn't worked so far, not sure what I am doing wrong. Tried on After Update, On Change, Click...
Private Sub UserIDs_AfterUpdate()
Me.User_Name = Me.UserIDs.Column(1)
End Sub
I don't how to create a column count if that's need.
Any help is greatly appreciated or other suggestions. I've spent a lot time reading through postings. Thanks all.