Hi. I have a combobox that look up from a table. Then I like the selection made in combobox to store this in another table. The problem i facing is that it stores just the ID of the combo selection in the table and not the text showed in combobox. How to set this correct:
This is what I have in combobox row source:
SELECT PersonalContact.ID, PersonalContact.Abbreviation
ORDER BY PersonalContact.Abbreviation;
Isent it another simpler way? I manage to store the ID of the combo selection (table). As mention I like to store the other column of the combo table.
So the combo table has 2 columns. ID and Name. It is the Name that is displayed and selected in combo. I like to store the Name in the main table. But it stores the ID when I select. I have no event so far to do this so I imagine it is a simple properties or query setup. Ex in the row source properties of combobox.
What ever code you are using to store the id just use the syntax combobox.column(1)
THAT WILL GRAB THE DATA THAT YOU ARE SEEING IN THE COMBOBOX. But that data is a string where as the id column is an integer - if you want to save that string data thwe same way you are saving the id data then you may get a data type error - the way I explained it to you - based on the minimal information you have given me - is the best most professional way to do this.