Combo Box Behavior

  • Thread starter Thread starter Phil M.
  • Start date Start date
P

Phil M.

I have a combo box that is coded to open immediately when the form opens.
The user can type in part of the word, and scroll to the correct entry using
the arrows and enter button.

When the enter button is pressed, I want the cursor to move to a certain
field in the form, AND I want the combo box to close. Is there any VB code
that can do this?

Thanks
Phil M.
 
To move to a spcific field set the focus to that field.

Me.NameOfControl.SetFocus

What do you mean by closing the combo box. If you mean to roll back up, it
should do it automatically. If you mean to make it disappear set the
Visible property to false.

Me.NameOfComboBox.Visible = False

You might have to set this back to True in the form's OnOpen event or else
you won't see it again.

Kelvin
 
Back
Top