Hi Ed,
Thank you for your interest in Syncfusion products.
Combobox does not support multiple selection. But you can achieve this by hiding the default dropdown which is displayed when dropdown button in the ComboBox is clicked. Then showing the listbox for multiple selection, and display the selected items in the cell.
Please refer the below code for more details.
Private Sub l_Click(ByVal sender As Object, ByVal e As EventArgs)
Dim cc As GridCurrentCell = Me.gridControl1.CurrentCell
l.Hide()
flag = 0
End Sub
Private Sub l_SelectedValueChanged(ByVal sender As Object, ByVal e As EventArgs)
Dim cc As GridCurrentCell = Me.gridControl1.CurrentCell
If (Me.gridControl1(cc.RowIndex, cc.ColIndex).CellType = "ComboBox") Then
Dim str As String = ""
For i As Integer = 0 To l.SelectedItems.Count - 1
str += l.SelectedItems.Item(i).ToString()
Next i
Me.gridControl1(cc.RowIndex, cc.ColIndex).Text = str
End If
End Sub
Private flag As Integer = 0
Private Sub gridControl1_CellButtonClicked(ByVal sender As Object, ByVal e As GridCellButtonClickedEventArgs)
l.DataSource = list
l.Height = 70
Dim x As Integer=(e.Button.Bounds.X+e.Button.Bounds.Width)-l.Width
Dim y As Integer = (e.Button.Bounds.Y + e.Button.Bounds.Width)
l.Location = New Point(x,y)
If flag = 0 Then
l.Show()
flag = 1
End If
End Sub
Private Sub gridControl1_CurrentCellShowingDropDown(ByVal sender As Object, ByVal e As GridCurrentCellShowingDropDownEventArgs)
e.Cancel = True
End Sub
Here is the minimal sample which implements this task.
http://websamples.syncfusion.com/samples/grid.windows/F74750/main.htmPlease let me know it this helps.
Best Regards,
Srirajan