Hi !
I set my SfCombo using a dictionary of strings as shown below:
comboGrupos.DataSource = New BindingSource(Grupos, Nothing)comboGrupos.DisplayMember = "Key"
comboGrupos.ValueMember = "Value"When I try to sort it using
comboGrupos.DropDownListView.View.SortDescriptors.Add(New Syncfusion.DataSource.SortDescriptor() With {.PropertyName = "Key", .Direction = Syncfusion.DataSource.ListSortDirection.Ascending})
I receive an error:
System.InvalidOperationException HResult=0x80131509 Message=There is no coertion operation defined between types 'System.Collections.Generic.KeyValuePair`2[System.String,System.String]' and 'System.String'. Source=System.Core
|
'Acending order
Dim My_dict1 As New SortedDictionary(Of String, String)()
'Decending order
Dim My_dict1 As New SortedDictionary(Of String, String)(New Form1.DescendingComparer(Of String)()) |
Hi Elakkyia!
Great! I didn't know SortedDictionaries at all!
Thanks a lot; it had functioned perfectly.
Kindest regards,
David