Combo Box and List Box

  • Thread starter Thread starter Kevin Baker
  • Start date Start date
K

Kevin Baker

Hi Everyone!

I have a list box on my form and I would like to put a combo box above the
list box (list0) and as the user type information (the combo box will
contain Purchase Orders in the following format: 5001-9700), as the user
begins to type 5 (the first record beginning with a 5 will be selected in
the list box, as the user continues to type the list box will keep updating
and going to the first record that means the criteria in the combo box.

Any ideals?

Thanks,
Kevin
 
Well Kevin...
I have to mention that the Combo box already does just that. Given that you
have AutoExpand = Yes, that's just what Auto Expand does. Check out
AutoExpand in Help... it's almost a verbatim quote of what your trying to
do.

Could you explain why you might have to use a list box to duplicate that
function?

If you must do a listbox, you'll have to use the OnChange event of the
combo. (It fires every time an individual character is entered in the
combo). That event could be used to trigger a Requery of the listbox using
a Criteria of...
Like [cboYourComboName] & "*"

hth
Al Camp
 
If you set Auto Expand to Yes in the combo box's Properties, the combo box
will do this automatically. The listbox isn't needed. If you still want to
do the listbox, yes it can be done, just post back.
 
Back
Top