![]() | Type | Description | ||
| FilterTypeEnum | A FilterTypeEnum expression that indicates the filter's type. |
The FilterType property defines the filter's type. By default, the FilterType is exAll. No filter is applied if the FilterType is exAll. The Filter property defines the column's filter. Use the DisplayFilterButton property to display the column's filter button. Use the FilterInclude property to specify whether the child items should be included to the list when the user applies the filter. Use the FilterCriteria property to filter items using AND, OR or NOT operators between columns.
The ApplyFilter method should be called to update the control's content after changing the Filter or FilterType property. The ClearFilter method clears the Filter and the FilterType properties.
The following VB sample filters "Child 1" and "Child 2" items:
With ComboBox1
With .Columns(0)
.Filter = "Child 1|Child 2"
.FilterType = exPattern
End With
.ApplyFilter
End WithThe following C++ sample filters "Child 1" and "Child 2" items:
CColumn column = m_combobox.GetColumns().GetItem(COleVariant(long(0))); column.SetFilter( "Child 1|Child 2" ); column.SetFilterType( 3 /*exPattern*/ ); m_combobox.ApplyFilter();
The following VB.NET sample filters "Child 1" and "Child 2" items:
With AxComboBox1
With .Columns(0)
.Filter = "Child 1|Child 2"
.FilterType = EXCOMBOBOXLib.FilterTypeEnum.exPattern
End With
.ApplyFilter()
End WithThe following C# sample filters "Child 1" and "Child 2" items:
axComboBox1.Columns[0].Filter = "Child 1|Child 2"; axComboBox1.Columns[0].FilterType = EXCOMBOBOXLib.FilterTypeEnum.exPattern; axComboBox1.ApplyFilter();
The following VFP sample filters "Child 1" and "Child 2" items:
With thisform.ComboBox1
With .Columns.Item(0)
.Filter = "Child 1|Child 2"
.FilterType = 3 && exPattern
EndWith
.ApplyFilter
EndWith