A
Andy G
I have a combo box that needs to be set to a value from another table. I do
a lookup on another table and then use the following to set the combo box,
Me.cmbCollege.SetFocus
Me.cmbCollege.SelText = myCollegeCode
The combo box row source is set to SELECT College.Coll_ID, College.Coll FROM
College;, bound column 1 and control source is Coll_ID. myCollegeCode is
simply a string that is set to the name of the college (not the Coll_ID),
but the myCollegeCode name does match one of the colleges in my row source.
I have many other combo boxes in the form and not sure it is erroring on
this specific one. The error I am getting says, "The value you entered
isn't valid for this field."
Any help would be good.
Thanks.
Andy
a lookup on another table and then use the following to set the combo box,
Me.cmbCollege.SetFocus
Me.cmbCollege.SelText = myCollegeCode
The combo box row source is set to SELECT College.Coll_ID, College.Coll FROM
College;, bound column 1 and control source is Coll_ID. myCollegeCode is
simply a string that is set to the name of the college (not the Coll_ID),
but the myCollegeCode name does match one of the colleges in my row source.
I have many other combo boxes in the form and not sure it is erroring on
this specific one. The error I am getting says, "The value you entered
isn't valid for this field."
Any help would be good.
Thanks.
Andy