vb.net DataGridViewComboBoxColumn
When using the editable DataGridViewComboBoxColumn it appears to be working almost great.
Users can either type a new value i开发者_开发百科nto the text or select a predefined option from the dropdown.
The problem is when somebody starts typing and a pre defined option appears when you click enter, tab, or right arrow to jump to the next field the option disappears from the list.
Any ideas?
Private Sub dgDetails_CellLeave(ByVal sender As Object, ByVal e As System.Windows.Forms.DataGridViewCellEventArgs) Handles dgDetails.CellLeave
If Not cb Is Nothing Then
cb.SelectedIndex = cb.FindStringExact(cb.Text)
End If
End Sub
精彩评论