All docs
V20.1
20.2 (EAP/Beta)
20.1
19.2
19.1
The page you are viewing does not exist in version 19.1. This link will take you to the root page.
18.2
The page you are viewing does not exist in version 18.2. This link will take you to the root page.
18.1
The page you are viewing does not exist in version 18.1. This link will take you to the root page.
17.2
The page you are viewing does not exist in version 17.2. This link will take you to the root page.

LookUpEditAutoSearchEventArgs.SetParameters(String[], String, FindPanelParserKind, FilterCondition) Method

Allows you to change how the lookup editor searches for items in its drop-down panel.

Namespace: DevExpress.XtraEditors.Controls

Assembly: DevExpress.XtraEditors.v20.1.dll

Declaration

public void SetParameters(
    string[] fieldNames,
    string text,
    FindPanelParserKind kind = FindPanelParserKind.Default,
    FilterCondition condition = FilterCondition.Default
)
Public Sub SetParameters(
    fieldNames As String(),
    text As String,
    kind As FindPanelParserKind = FindPanelParserKind.Default,
    condition As FilterCondition = FilterCondition.Default
)

Parameters

Name Type Description
fieldNames String[]

Names of fields whose values should be compared with the search text.

text String

A text to compare with data source records.

Optional Parameters

Name Type Default Description
kind FindPanelParserKind

0

If a text entered into the editor text box contains whitespaces, the editor splits this string into separate logical blocks. This parameter specifies how these blocks are combined into a search query.

condition FilterCondition

3

The condition according to which the editor searches for the string entered into its text box.

Remarks

The example below illustrates how to limit the search by the "Ship Country" and "Ship City" fields, and change the search condition to "Starts with...".

search

lookUpEdit1.AutoSearch += OnAutoSearch;

void OnAutoSearch(object sender, LookUpEditAutoSearchEventArgs e) {
    string[] fields = new string[] { "ShipCity", "ShipCountry" };
    e.SetParameters(fields, e.Text, FindPanelParserKind.And, FilterCondition.StartsWith);
}
See Also