Unanswered: Want Combo-box to populate another field in same form
I have a Product ID field which is a combox whose dropdown displays 2 columns (Product ID Code, Product Name) so the user can select the proper ID based on the name. When selected, only the ID Code displays and writes to the table. I would like the next textfield (Product Name) to populate automatically.
I've tried to add the AfterUpdate on the ProdcutID field to say Me.ProductName = Me.ProductID.Column(1) but this is not working.
I found a way to have my combobox (ProductID) configured so that when a value is selected, it automatically fills in the associated text box (ProductName). The combobox has 2 columns of data (I used the LookupWizard to do this), and I have this code in the Source for the text box: =ProductID.Column(1) in order for the proper name to populate.
This works fine except that the text box value is not writing to the table.
This works great for my combo boxes that have more than 1 row, however, for the DB I am building there is a need to have a form with a combobox with only 1 row (I know this is silly but the form must look EXACTLY like the PDF). I can set the default to display the correct row with setting the Default Value to [DistrictID].[ItemData](0), however, the DistrictName text field only displays when I manually re-select the DistrictID combobox (even though it is already selected at default).
Is there a simple way to have the text field also selected at default, or if not, is there a way to the have the text field DistrictName default to the correct name?