SearchStringToFilterCriteriaEventArgs.Highlighting Property
Gets or sets highlighting strings for fields.
Namespace: DevExpress.Xpf.Grid
Assembly: DevExpress.Xpf.Grid.v24.1.Core.dll
NuGet Package: DevExpress.Wpf.Grid.Core
Declaration
Property Value
Type | Description |
---|---|
List<FieldAndHighlightingString> | Highlighting strings for fields. |
Remarks
private void TableView_SearchStringToFilterCriteria(object sender, DevExpress.Xpf.Grid.SearchStringToFilterCriteriaEventArgs e) {
e.Filter = CriteriaOperator.Parse(string.Format("Contains([Name], '{0}') OR Contains([Id], '{0}')", e.SearchString));
e.Highlighting = new List<FieldAndHighlightingString>((sender as TableView).VisibleColumns.Select(c => new FieldAndHighlightingString(c.FieldName, e.SearchString)));
}
See Also