Previously entered Data is not displayed in combo box

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

I have a combo box that is used to select a vendor assigned to a particular
customer. The combo is based on a select query statement which limits the
selection to only the current vendors assigned to the customer. As long as
the vendor does not change, the vendor code shows up in the combo box. If
the vendor is changed, the old vendor is no longer displayed in the form even
though the old vendor code data is still there (which is what we want). It
is confusing to the users because they see a blank feild. We would like for
the old vendor code to display in the field even though it is not a "current
choice" in the combo box. Any remedies?
Thanks for your help

Jeff G
 
Presumably you are changing the Vendor info in the background. After doing
this you need to requery the combo control to get the latest data.
cbo.Requery
 
I have a combo box that is used to select a vendor assigned to a particular
customer. The combo is based on a select query statement which limits the
selection to only the current vendors assigned to the customer. As long as
the vendor does not change, the vendor code shows up in the combo box. If
the vendor is changed, the old vendor is no longer displayed in the form even
though the old vendor code data is still there (which is what we want). It
is confusing to the users because they see a blank feild. We would like for
the old vendor code to display in the field even though it is not a "current
choice" in the combo box. Any remedies?
Thanks for your help

Jeff G

This can be done, though it's a bit tricky. Put a Textbox on the form,
carefully superimposed over the text area of the combo box. Its
properties should be:

ControlSource: the vendor name, from a joined table in the Form's
Recordsource query or from a DLookUp()
Enabled: No <so the user can't edit it>
Locked: Yes <so it's not greyed out>
TabStop: No <so the user can't tab into it>

The textbox will show the current record's vendor, regardless of
what's in the combo; when the combo is dropped down, it will jump in
front of the textbox and allow a selection.

John W. Vinson[MVP]
Join the online Access Chats
Tuesday 11am EDT - Thursday 3:30pm EDT
http://community.compuserve.com/msdevapps
 
thanks- I will give it a try.

John Vinson said:
This can be done, though it's a bit tricky. Put a Textbox on the form,
carefully superimposed over the text area of the combo box. Its
properties should be:

ControlSource: the vendor name, from a joined table in the Form's
Recordsource query or from a DLookUp()
Enabled: No <so the user can't edit it>
Locked: Yes <so it's not greyed out>
TabStop: No <so the user can't tab into it>

The textbox will show the current record's vendor, regardless of
what's in the combo; when the combo is dropped down, it will jump in
front of the textbox and allow a selection.

John W. Vinson[MVP]
Join the online Access Chats
Tuesday 11am EDT - Thursday 3:30pm EDT
http://community.compuserve.com/msdevapps
 
Back
Top