Based on the example here - http://www.telerik.com/help/winforms/multicolumncombobox-filtering.html
I cannot get the composite filters to work. The single filter works fine.
Based on the code below, once I bind the data to the datasource, the DisplayMember is automatically set to the first column, in this case Account. The documentation says the data is filtered by the DisplayMember field. So this works fine for the single column filter.
For the composite filter, no filtering takes place. You can see from the attached debug image that the filter is being set correctly.
> Is it because the DisplayMember is only set to "Account"?
> Can it be set to something that would work correctly (eg: Account, Description)?
If the composite filtering does not work, please remove it from the Telerik documentation or detail how to get it to work. A two column drop down is a pretty simple example. BTW I am on Winforms v2013.3.1127.40
Thanks!
Dim
sSql
As
String
=
"Select Account, Description From accounts Order By Account"
cbo.DataSource = tbl
'THIS single filter section works fine
cbo.AutoFilter =
True
Dim
filter
As
New
FilterDescriptor(cbo.DisplayMember, FilterOperator.Contains,
""
)
cbo.EditorControl.MasterTemplate.FilterDescriptors.Add(filter)
'THIS composite filter does not work - duplicated from Telerik example
'Dim cmpFilter As New CompositeFilterDescriptor()
'Dim fltMain As New FilterDescriptor(cbo.DisplayMember, FilterOperator.Contains, "")
'Dim fltDesc As New FilterDescriptor("Description", FilterOperator.Contains, "")
'cmpFilter.FilterDescriptors.Add(fltMain)
'cmpFilter.FilterDescriptors.Add(fltDesc)
'cmpFilter.LogicalOperator = FilterLogicalOperator.[Or]
'cbo.EditorControl.FilterDescriptors.Add(cmpFilter)